[Ipe-discuss] Ipe 6 pre 9 compile error

Otfried Cheong o.cheong at tue.nl
Thu Mar 27 13:50:22 CET 2003


René van Oostrum writes:
 > Upon compiling Ipe 6 preview 9 on Redhat Linux I got the following error
 > 
 > ../include/ipecolor.h: In member function `virtual void 
 >    IpeMark::Draw(IpePainter&) const':
 > ../include/ipecolor.h:105: `IpeAttribute::IpeAttribute(int)' is private
 > ipemark.cpp:116: within this context
 > 
 > Commenting out line 104 of ipecolor.h so that the constructor becomes
 > public solved the problem, and Ipe seems to run fine. Should this
 > constructor be explicit?

That's the wrong constructor, and the generated PDF output will be
wrong.

This is very mysterious.  I hadn't noticed the problem because MSVC
reports only a warning (which I had missed)!  It's completely unclear
whether it actually compiles in a call to the private constructor or
what it does.

The solution is to change the offending line in "ipemark.cpp" like
this:

  painter.SetLineWidth(IpeAttribute(IpeAttribute::ELineWidth, 0.4));

I've replaced the current copy of Ipe on the webpage with a corrected
version (assuming you are the first to try to compile it).

Cheers,
 Otfried





More information about the Ipe-discuss mailing list