[Development] QAction-like API for QML

Bache-Wiig Jens Jens.Bache-Wiig at digia.com
Tue Dec 18 10:42:10 CET 2012

> Now, you've most likely seen way more Qt apps than I have, but all I have seen 
> were shipping icons, most of them as part of their resources, some as files.

I am pretty sure this is a misunderstanding. We do not bundle the icons inside the Qt libraries. People bundle it with their application executables. I.e they put their "edit-copy.png" file inside their application resources, just like we do in our examples.

> Both mechanisms which by design load icon data by name, so at least from my 
> empirical data I am quite puzzled to learn that iconName would be sufficient 
> for specifying icons.

On Linux and related open source platforms there is an established icon naming standard. The linux distributions are free to ship their own icon themes as long as they follow the naming convention. This makes it possible to use icons by logical names like "edit-copy" instead of referring to explicit png files bundled within your application resources. It saves time, space and makes applications more consistent since they can use the same icons across different applications. 

It is a nice concept but my only point was that we cannot rely on it alone since it makes the app useless on Windows and Mac. It would be neat to include icons in Qt but that would essentially be like bundling all of the Oxygen icons in every single KDE application and beats the purpose of it.

> Drawing icons on demand sounds very cumbersome to me.

That was certainly not what I was trying to suggest. I hope that clarifies things. :)


More information about the Development mailing list