> data. When you save an image als ".xpm" and open it with a 
> text editor, 
> it is easy to see, how to use it. There is something like
> "static const char * const pXPM_Pic[] = {...}" and you can use this 
> pointer directly. Maybe there is less "const", but you should 
> add it, to 
> get rid of compiler warnings.

Yes - many image editor tools can save an image to an XPM, and the XPM
format can have transparency too.
I usually generate the image as a PNG or GIF then have gimp or
imagemagic convert it to XPM and that generally seems to work.

You can then just compile that into your code as a "resource" for later
use.

Though, as Edzard says, you may need to hand-edit the XPM a little, as I
find that the C++ compilers tend to whine about the format somewhat,
though plain-C compilers tend to be more forgiving. Usually!

Or you can load the image at runtime, but then you need multiple files
for you app, and maybe some installation process, and...




SELEX Galileo Ltd
Registered Office: Sigma House, Christopher Martin Road, Basildon, Essex SS14 
3EL
A company registered in England & Wales.  Company no. 02426132
********************************************************************
This email and any attachments are confidential to the intended
recipient and may also be privileged. If you are not the intended
recipient please delete it from your system and notify the sender.
You should not copy it or use it for any purpose nor disclose or
distribute its contents to any other person.
********************************************************************

_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to