qdatawidgetmapper for displaying qicons?

I'm currently trying to create a widget which allows me to display properties of a given tool. I have a model containing all tools, and what i would like to create is basically a combobox which allows to select one tool and the tools properties are then displayed using icons.

my model already has defined different roles e.g. decoration and display role, but i'm wondering how to build a widget which only reacts on the decoration role of the model.

thanks a lot in advance donny

Answers


Try a QLabel

Specifically mapping its pixmap property:

myMapper.addMapping(myLabel, itsSection, "pixmap")

Need Your Help

Error: Calendar cannot be resolved in JSP

java jsp date get

I tried to get date in JSP like what I searched before, but it didn't work. Here is my code.

htaccess rewrite all subfolders (/../..) to index.html

regex apache .htaccess mod-rewrite

I am creating a one page application. When the user changes the url, or reloads, anything after "mysite.com/" is sent as a variable to ajax the requested subdirectory content (e.g. /users/me)