Canvas item drawn outside the canvas

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Canvas item drawn outside the canvas

Michael González Harbour
Hello,

I am using a Gtkada Canvas with Gtkada 3.8.2 and I found that sometimes
the canvas items are drawn outside the canvas itself. I found that this
happens also with testgtkada. This effect happens when I move an item to
the top of the canvas with part of it outside and then I redraw the
window, for instance by minimizing it and maximizing it.

This effect did not happen in previous versions (3.4.x, for instance).

In my application I use large diagrams and this effect is very visible.
Is there any workaround that you can propose?

Thanks,

Michael.

--
-----------------------------------------------------------------------
Michael Gonzalez Harbour                  E-mail: [hidden email]
Grupo de Computadores y Tiempo Real       URL: http://www.ctr.unican.es
Facultad de Ciencias                      Phone : +34-942-201483
Universidad de Cantabria                  Fax   : +34-942-201402
Avda. de los Castros s/n
E-39005 Santander
SPAIN
-----------------------------------------------------------------------

_______________________________________________
gtkada mailing list
[hidden email]
http://lists.adacore.com/mailman/listinfo/gtkada
Reply | Threaded
Open this post in threaded view
|

Re: Canvas item drawn outside the canvas

Emmanuel Briot
> I am using a Gtkada Canvas with Gtkada 3.8.2 and I found that sometimes the canvas items are drawn outside the canvas itself. I found that this happens also with testgtkada. This effect happens when I move an item to the top of the canvas with part of it outside and then I redraw the window, for instance by minimizing it and maximizing it.

I am not sure what you mean by "drawn outside the canvas".
I assume this is simply that the item is not visible in the canvas when you expect it to be ?
(which would point to a bug in the mechanism that tests whether an item's bounding box
intersects the currently visible area).
I wasn't able to reproduce a similar issue with testgtk on my machine.

Future versions of GtkAda include a fully redesigned canvas widget, named Gtkada.Canvas_View,
which provides a much cleaner API and easier ways to create the items from simple base forms.

regards
Emmanuel

_______________________________________________
gtkada mailing list
[hidden email]
http://lists.adacore.com/mailman/listinfo/gtkada