Thanks for checking this, Fabien.
I'm out and about today, so will not get a chance to try this on a Mac
until tomorrow now...
> the good news is: it does work (though you have to resize the
> box on both win32 and mac os x to see the weather sensitive
> lunatic triangle) !
> the bad news is : now we have to find what's wrong in your config
>
> Conditions of test:
> -------------------
> Mac OS X 10.5.4
> Fltk 1.3 svn
> Cairo 1.6.4
OK, for this test I had OSX 10.4.11, fltk-1.1.9-svn, Cairo-1.6.4
> What I did:
> -----------
>
> First, I tested on win32, only the line context->surface is
> erroneous and it works fine when replacing with the surface
> var. that you defined upper in the code.
Oops - that's a typo left over from converting the "real" code to make
up this demo. Sorry.
(The real code has a "context" struct that is passed around to allow
rendering using different back-ends.)
> Also, I added the following line:
> test->redraw()
> before the Fl::run() call so that it is refreshed otherwise
> you have to resize the window to make it work.
OK, seems like a good idea.
> Then on MAC OS X,
> I compiled and linked against usual fltk libs + libcairo.a
> and libpixman-1.a
> Then run, -> works !
And the triangle is the right way up?
> If after testing my modifications, it still doesn't work,
> check first the cairo-features.h in the cairo/ include subdir
> where you installed it.
> In particular, check that the Quartz rendering defines are enabled ok.
> Also check that your configure is using Quartz and not QD.
>
> If it still doesn't work, then try removing cairo and install
> it via the MacPort command:
> sudo port install cairo
This is a Cairo lib I built from source, but it does work OK - other
things using it directly are fine - but I am having issues getting it to
play nicely with fltk in this program, on OSX.
The basic rendering seems to work, just upside down, hence the commented
out;
// cairo_scale(cairo_context, 1, -1);
In the demo, where I was trying to get the context back the right way
up.
In the "real" code I have changed that to:
cairo_scale(cairo_context, 1, -1);
cairo_translate(cairo_context, 0.0, -ho);
And that seems to mostly work, in that the image is the right way up and
more or less in the right place, but it still isn't doing what it does
on Linux or win32, and I still have problems with font rendering...
It is a puzzle....
Thanks for the input,
--
Ian
SELEX Sensors and Airborne Systems Limited
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