PDA

View Full Version : Is is possible to have Icons deternined at runtime?



feraudyh
18th April 2011, 17:33
As far as I understand, icons for buttons and toolbars are usually compiled into the program and so cannot be changed once the program is compiled.
Please correct me if I am wrong.
I'm hoping to develop a Qt Application with a toolbar whose buttons have icons that come from a list of bitmaps that are referenced in a text file which is read when the program starts up.
Does this sound reasonable?

high_flyer
18th April 2011, 17:47
Please correct me if I am wrong.
You are wrong if you mean that the usage of the resources can not be determined in runtime.
If you use a resource file, you can compile your resources in to your exe, but you can choose to use them at any time you like.
You don't have to use a resource file, you can also load resources at runtime from external files.

feraudyh
18th April 2011, 21:02
Thanks,
Good news, so I shall search the documentation for the word resource.