This is an explanation of a Qt/C++ program written with Qt Creator IDE to draw a line or rectangle dynamically on a QWidget. I start from the basics as this is my second write up on Qt/C++. Here first a linewidget class is created by subclassing from QWidget. Also concurrently Qt Creator generates a file named linewidget.ui to assist in developing … Continued
Qt/C++
Understanding Qt/C++ basics
Let’s first discuss some definitions: Macro: A macro is a fragment of code which has been given a name. Whenever the name is used, it is replaced by the contents of the macro. Preprocessor: is a program that converts a .cpp source file containing # directives (such as #include, #ifndef etc) into a source file that contains … Continued