Big object disapearing

Hello,

I'm still working on my big grid, and I've that GoDiagram works pretty well.
I'm now facing a strange problem :
I'm having a layer for selection (above all others) and I'm creating transparent rectangles in it (object derived from GoRectangle - no override from ComputeBounds or Paint). I set the bounds of the rectangle to a given height and to the width of the document (so I can scroll without to update my rectangle bounds).
With a with of 8'107'968.5f it is still ok, with 9'324'163.0f, the bounds are set correctly but the object is not any more drawn.
Any idea ?
Thanks
Regards
Didier Kuttel

Very large objects (i.e. width or height of millions, depending on scale) will cause GDI+ errors. I don’t know of any work-around for that.

If the rectangle is transparent, how could you tell that it wasn't being painted?
Better question: why are you creating huge transparent objects? I don't understand what you are saying about scrolling. There's probably another way to get the effect you want.

Hello,

My object is only partially transparent (to see th lower levels).
I'm using the diagram framework for a graphical grid, and I'm representing the row selection with a rectangle over the grid. I set the size for this rectangle to a row height and to the document width. Afterwards I can scroll my document, the selction rectangle is always ok.
But with very large documents, my rectangle has a very big width and disappear (probbaly as you explain GDI+).
So I've probbaly to manage my selection in another way ... :-(
Thanks
Bye
Didier

One possibility is to break up your one rectangle into a bunch of smaller ones.

Or override GoGrid.FillGrid.
Or better yet, replace your single "selection" rectangle with a GoGrid whose Bounds are the Bounds of the first cell in the selected row, but with UnboundedSpots == GoObject.MiddleRight. Use the same Brush as you did with your GoRectangle.

Ok, thanks,

Will give a try.
Bye
Didier

Try with several rects, works fine.

Thanks
Bye
Didier