PDA

View Full Version : Using images as standalone files or not



ape
19th December 2007, 13:30
Hello again,

i am using 2 *.png files which are displayed in my application via QPixmap.

My question:
Is it possible to include those images into my application.exe ?
Or am i forced to have them as sep. files ?

I would prefer an inbuilt solution, as noone would be able to just replace the source-files.....which would result in a diffrent ui-view

I guess you got my point.

A keyword for that topic would be highly appreciated.
Best regards in advance
ape

edit:
Part 2:
At the moment my *.exe needs 3 Qt dll-Files to work on a system without a preinstalled qt-environment. Basicly it would be great to have a solution to include those files too.

I guess using an installer would be a solution but in best case i would just end with a single .exe file which contains everything.

marcel
19th December 2007, 13:34
Question 1: see the Qt Resource system :http://doc.trolltech.com/4.3/resources.html
Question 2: What about static linking?

ape
19th December 2007, 14:02
Hi Marcel,

regarding question 1:
--
Thank you very much. That hint was 1:1 what i was looking for.
Works like a charme



regarding question 2:
--
Actually i must admit i am not really sure what you mean with static linking.

The app just works if i copy those 3 needed qt-dll's into the same folder/location then my *.exe is located. So i dont see a reason to link them in general.

The idea was just similar to the images in question 1, but i guess i have to google for static linking in Qt related context.


Thanks again
ape