Posts

Qt Snippet: Set background color of a widget

Image
Is possible to easily set the background color of a widget by changing the palette of widget itself.

Qt Snippet: Remove all rows from QTableWidget

Image
QTableWidget is the Qt widget that, as the name suggest, show a table composed by cells able to contain both native field like text or icon and also more complex widgets like listbox, checkbox and so on.

Android.mk: include multiple source files using wildcards

Image
In case your Android project consist in a lot of source files you should, normally, add one by one to the LOCAL_SRC_FILES label and this could be a very boring task to complete. Fortunately there is the possibility to make addition of multiple files using wildcards in a very easy way. Let's go to see how to make it.

Configure Eclipse to go through a proxy

Image
Eclipse IDE have some specific repositories containing various extensions, plugins and so on. Usually Eclipse is able to download and install all these components by directly accessing to Internet Some problem can happen if your network need a proxy access. Here a short guide on how to configure proxy access into Eclipse.

Qt Snippet: Set window icon in Linux and Mac

Image
In case of use Qt for Windows development the problem of the icon showed as window system icon is automatically resolved by add the .ico file as Windows resource. Windows already allow such feature and no need of additional efforts. In case of same code ported and compiled under Linux or Mac this step is not automatic.

Qt Snippet: Create QPixmap with transparent background

Image
If you want to create a QPixamp object with transparent background you simply need to fill the entire area with transparent color immediately after created. After doing this you can start to draw over.

Qt Snippet: Draw into QPixmap

Image
Draw inside QPixmap can be made using QPainter object. Basically you have to pass to QPainter the pointer to your QPixmap (already created with fixed size) and you can draw inside as the same of window area painting.