Drawing sections of graph at a time [message #227566] |
Thu, 07 December 2006 05:55 |
Eclipse User |
|
|
|
Originally posted by: ruth.hawkins.yahoo.com
Hi
I am a new user of GEF Tool. I want to know how can I efficiently draw
figures only on the visible area of the editor. I am trying here to draw
"RectangleFigure" and the length of the rectangle is pretty huge which
goes well beyond the screen width. Drawing the entire rectangle at once
does not make sense. And also if I want to draw multiple rectangles which
are separated by large distances, then the figures which are not within
the visible range need not be displayed.
Please, provide me with some information on drawing only sections of the
entire graph rather than loading all at once.
Thanks!
Ruth
|
|
|
|
Re: Drawing sections of graph at a time [message #227598 is a reply to message #227574] |
Fri, 08 December 2006 06:22 |
Eclipse User |
|
|
|
Originally posted by: ruth.hawkins.yahoo.com
Hi Alex,
Thanks for the suggesstion. I will try to put it for my use.
I have another query though, is it possible to have 'n' data models but
have only 'm' figures, where 'm < n'. I want to build a framework where I
can have a factory of figures and I will request a figure when the area in
which it is required to be drawn is visible.
For example, I have a data model which is required to be mapped to a
RectangleFigure on the graph. This figure needs to be drawn at a location
say x=9000 and y=100. Initially, when the graph is shown at x=0 and y=0
this figure needs not be displayed and hence should not be instantiated.
Though, when the graph will be scrolled horizontally and will reach at the
position x = 9000 a figure will be instantiated and hence drawn at the
required location.
I want such an architecture because in my graph there are huge number of
figures to be drawn and my tool is going out of memory soon with large
number of figures on the graph. So I want to reduce the number of figure
objects created before they are actually displayed.
Thanks!
Keya
|
|
|
Powered by
FUDForum. Page generated in 0.02764 seconds