Marco, Thanks for your interest in FloatCanvas, and Matt, thanks for your assessment of the situation. A few comments:
> I am not sure whether FloatCanvas1 can handle images which are rotated > and zoomed at the same time, maybe Chris will answer this. Matt is correct, FC1 does not do rotation of images. It wouldn't be too hard to add to the ScaledBitmap class, but it might get a bit tricky to translate coordinates from world to the pixel coords of the image -- FloatCanvas doesn't have any concept of rotation, so that would have to be handled by the ScaledBitmap class itself. > It works quite well on windows, but other platforms like mac and gtk > have problems which render it unusable at this time. I thought we'd fixed the Mac issue -- I'll have to check that out again. And if you are on GTK, we could use a GTK tester/developer. It'll be a bit tricky to find the issue, but it's probably only a couple lines of code when you do! > From what I gathered so far this looks like we could replace > wx.GC with the cairo version of it. However it seems text rendering and > fonts are not yet implemented. Replacing wx.GC with the cairo GC would > probably need some testing, but it seems it's able to make floatcanvas2 > work without the problems and on all platforms. I'm not sure about that -- you still need to get the image to the screen, and I think that's where the issues are. But Cairo would get us fully floating point coords, exactly the same rendering everywhere, and other output options: PDF, printing, PS, SVG? > Of course you'd need to > install cairo on windows then to make it work. Yes, though I think Robin is open to the idea of bundling Cairo with wxPython in the future if it starts getting wider use. >> It sounds floatcanvas2 is going to be the official library soon. Well, I'm not sure. I think FC1 will be around for a while. I will hopefully soon be putting substantial efforts into an app that needs one or the other, and I haven't made my decision as to which I'm using. The key problem now is that with the rewrite, we've gotten some great new functionality and more flexibility, but also lost some features and maturity. >> so, I'd prefer to program with this library since the beginning but I >> am afraid that some functionality I might need in the next months is >> not implemented in floatcanvas2 yet. I'd say give it a try and post questions here, and you'll see where you stand. We really do need to make sure GTK and MAc are working right soon, and maybe you can help get it there. > Yes, as stated above there are some things that don't work. If you are > on windows and don't need constant-screen-sized lines fc2 should be > usable for your task. About the constant-screen-sized lines -- it seems with GCs, we should be able do it, at least for when the world-coord size of the lines or fonts are greater than one, and we can kind of fudge that by scaling world coords up if need be, at least to get the infrastructure in place. > I think both FloatCanvasses provide the ability to do this. In fc2 you > can call canvas.pointToWorld( mouse_pos ) if FC1, it's Canvas.PixelToWorld() > Instead of calling > pointToWorld yourself you can instead use the fc2 event handling for > this. same in FC1 - the mouse events have an extra attribute: event.Coords() that is the coords of the event in World Coords. See various demos. Do let us know what you discover. -Chris -- Christopher Barker, Ph.D. Oceanographer Emergency Response Division NOAA/NOS/OR&R (206) 526-6959 voice 7600 Sand Point Way NE (206) 526-6329 fax Seattle, WA 98115 (206) 526-6317 main reception [EMAIL PROTECTED] _______________________________________________ FloatCanvas mailing list [email protected] http://mail.mithis.com/cgi-bin/mailman/listinfo/floatcanvas
