Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » Draw, Display, Images, Bitmaps, Icons » how to #define/#include correctly the .iml file
Re: how to #define/#include correctly the .iml file [message #3448 is a reply to message #3433] Thu, 25 May 2006 19:03 Go to previous messageGo to previous message
forlano is currently offline  forlano
Messages: 1207
Registered: March 2006
Location: Italy
Senior Contributor
luzr wrote on Wed, 24 May 2006 22:39

Wrong.

"iml.h" is just combination of "iml_header.h" and "iml_source.h" - means it causes troubles if you have any of them (duplicite symbols).

Also, repeat CLASSNAME define for any include.

Mirek



Thank you. After many tests I've resolved the problem and now even the linux version works Very Happy . Perhaps maybe useful to let know how I've distributed the define and include:

vegamain.h (stay everywhere in each cpp file)
 ...
#define IMAGECLASS    Vega3Img  
#define IMAGEFILE     <Vega3/Vega.iml>
#include <Draw/iml_header.h> 
...


vegamenu.cpp (uses some images in Vega.iml)
...
#define IMAGECLASS    Vega3Img    
#define IMAGEFILE     <Vega3/Vega.iml>
#include <Draw/iml_source.h>  


vegatab1.cpp (uses some images in Vega.iml)
...
//#define IMAGECLASS    Vega3Img // with it I got error   
#define IMAGEFILE <Vega3/Vega.iml>
#include <Draw/iml_source.h>
...


in the previous file if I use "#define IMAGECLASS" the compiler complains
C:\Vega\Vega3\VegaTab1.cpp: In function `void Avail3(One<Ctrl>&)':
C:\Vega\Vega3\VegaTab1.cpp:49: error: `imgYes' undeclared (first use this function)
C:\Vega\Vega3\VegaTab1.cpp:49: error: (Each undeclared identifier is reported only once for each function it appears
	 in.)
C:\Vega\Vega3\VegaTab1.cpp:49: error: `imgNo' undeclared (first use this function)
C:\Vega\Vega3\VegaTab1.cpp:49: error: `imgMaybe' undeclared (first use this function)
C:\Vega\Vega3\VegaTab1.cpp: In constructor `VegaTab1::VegaTab1()':
C:\Vega\Vega3\VegaTab1.cpp:89: error: `imgYes' undeclared (first use this function)
C:\Vega\Vega3\VegaTab1.cpp:128: error: `female' undeclared (first use this function)
C:\Vega\Vega3\VegaTab1.cpp:128: error: `male' undeclared (first use this function)
Vega3: 1 file(s) built in (0:08.07), 8078 msecs / file, duration = 8094 msecs


vegatab4.cpp (uses some images in Vega.iml)
... 
#define IMAGEFILE <Vega3/Vega.iml>
#include <Draw/iml_source.h>
...

But this last one works even if I set
... 
//#define IMAGEFILE <Vega3/Vega.iml>
//#include <Draw/iml_source.h>
...


Luigi
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: How to show the plot of a function
Next Topic: How to display an icon on the right side of a label/button
Goto Forum:
  


Current Time: Wed Jun 18 21:03:00 CEST 2025

Total time taken to generate the page: 0.03663 seconds