Hi all,

sorry for responding my own mail.

On Tuesday 11 April 2006 21:57, Werner Hoch wrote:
> I'd like to hear some comments about how to fix the rubberband relics
> when zooming while drawing.
>
> All zooming/paning actions have the following actions:
> * Save the current rubberband points (SCREENtoWORLD ...)
>     at the moment only start_x/y and last_x/y (second_x/y is missing)
> * recalc the drawing area
> * redraw all objects
> * recalc the saved points (WORLDtoSCREEN ...)
> * the redraw of the rubberbands  << missing code
>
> At the moment the redraw of the rubberbands are missing.
> With the next mouse-move-event a XOR-PUT to the (not existing)
> rubberbands are made and the new rubberbands are drawn.
>
> The XOR-PUT of not existing rubberbands causes the rubberband relics.
>
>
> I guess that implementing the redraw of the missing rubberbands is
> not that easy.
> Instead implementing the statment "there are no rubberbands" would be
> easier. Just set every variable of the rubberband to it's "start"
> value.
> The "start" values are those that are in the object draw start
> functions.
>
> For the net it would be: (o_net_start()):
>   last_x=second_x=start_x;
>   ...
>
> The circle needs: (o_circle_start()):
>   last_x=start_x;
>   distance=0;
>   ...
>
> Ok. Now the length of all rubberbands are zero and there are no
> rubberbands on the screen.
> With the next mouse-move-event the rubberbands are redrawn and
> everything is fine.
>
> What do you think about the concept?

I put the code to CVS last week. Well it is the right way to go as long 
as we have no elements that require more than 2 user actions (like 
splines).

Following things should work without errors:
* draw primitiv objects (line, arc, circle, net, bus, box, zoombox)
* move and copy of complex objects

> Do you expect bad side effects?

There are some extra XOR-drawings necessary to make move and copy work.
You'll may notice it if you move several large symbols and do some 
zooming actions.


[...]
> For other zooming/paning actions and objects the code doesn't work
> that well. There are a lot of places where minor changes are required
> to make zoom-while-drawing work completely. Tracking them will take a
> while.

Works for all zooming/paning actions now. See Changelog notes.

Things that don't work yet:
* zoom while modifying objects 
e.g. resize a box and zoom

Rubberband errors not related to zoom/pan.
Jumps between x_states:
* e.g. start drawing a net while drawing a box
a intermediate SELECT state is required to solve this

Component placement:
* zooming while component placement does not change the size of the 
symbol

Let me know if you see any problems with the changes.

regards
Werner

Reply via email to