[snip]

> Patrick, regarding your comment about checking if w_current->DONT_REDRAW is 1 
> before calling the
> redraw function, see the gschem and libgeda changelog, and take a look into 
> o_basic.c, function
> o_redraw_all:
>       case(ENDCOPY):
>       case(ENDMCOPY):
>       case(DRAWCOMP):
>       case(ENDCOMP):
>         /* Call the o_draw_list without redrawing, so the components */
>         /* coordinates get recalculated */
>         redraw_state = w_current->DONT_REDRAW;
>         w_current->DONT_REDRAW = 1;
>         o_draw_list(w_current, w_current->page_current->complex_place_list); 
>         w_current->DONT_REDRAW = redraw_state;
>         o_drawbounding(w_current,
>                        NULL,
>                        w_current->page_current->complex_place_list,
>                        x_get_darkcolor(w_current->bb_color), FALSE);
>         break;
> o_draw_list doesn't perform any draw operation because DONT_REDRAW is 1. 
> However, if I remove
> that call, the object is not displayed properly (when zooming while moving or 
> copying).
> I'm not too happy with this, but it is the way I found to make it work. Do 
> you have an idea?

Personally, I'd like to see the complete removal of cached screen coords
unless it is deemed absolutely necessary. I did a brief (huge patch)
test of this some months back, and discovered that at least for zooming
(and possibly panning?) a large schematic, the speedup is noticable by
_removing_ the caching. (Since a lot of recalculation is done at each
zoom).

Removing cached screen coords (at least in their present form) is
necessary to implement multiple views on a single open page. If
necessary, perhaps it could be implemented in a more abstracted fashion,
with cached coordinates saved per view, and invalidated / updated as
necessary, rather than en-masse.

The drawing code is much simplified by the removal of the cached coords,
and whilst there are only a few minor redraw bugs in gschem at the
moment, I suspect it will be easier to get _zero_ redraw bugs without
the extra complexity of the recalculation system at present.

Regards

-- 
Peter Clifton

Electrical Engineering Division,
Engineering Department,
University of Cambridge,
9, JJ Thomson Avenue,
Cambridge
CB3 0FA

Tel: +44 (0)7729 980173



_______________________________________________
geda-dev mailing list
[email protected]
http://www.seul.org/cgi-bin/mailman/listinfo/geda-dev

Reply via email to