PDA

View Full Version : Abusing the resourece system



elcuco
14th February 2008, 20:54
I have seen in wysota abusing the internal resources in Qt4 in his library: wwWidgets
http://www.wysota.eu.org/wwwidgets/

Does anyone (wysota...?) have a documentation about the images which can be used...? The portability/stability of those "files"?

jpn
14th February 2008, 21:38
See Embedded resources.

elcuco
14th February 2008, 22:33
Sweet. Do you have any idea about the portability of those icons? Qt4.2? 4.3? Windows? Mac? Linux?

(so far it seems to work as expected tough thanks!)

Edit:
... except QtDesigner 4.2 just sux, it puts on my files this in the UI file:



<property name="icon" >
<iconset>../../../../../../../../:/trolltech/styles/commonstyle/images/standardbutton-no-16.png</iconset>
</property>


Just edit the file with your favorite text editor, and you are done.

Brandybuck
15th February 2008, 00:24
Sweet. Do you have any idea about the portability of those icons? Qt4.2? 4.3? Windows? MEdit:
... except QtDesigner 4.2 just sux, it puts on my files this in the UI file:
Create your resource file first, then you select an icon, choose it from the resource instead of from a file. You can do it all in Designer. To create new resources, select Tools -> Resource Editor. Then in the Find Icon dialog, select the "Specify Resource" radio button. You can now browse the resources like they were files.