discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Problem ... very slow scrolling.


From: Enrico Sersale
Subject: Re: Problem ... very slow scrolling.
Date: Thu, 31 Jan 2002 21:12:04 +0200 (EET)

On Thu, 31 Jan 2002, Adam Fedor wrote:

> Richard Frith-Macdonald wrote:
>
> >
> > Looking at the code for NSCopyBits(), it uses DPScomposite, which (in
> > the xgps backend)
> > grabs an image from the source, manipulates it (alpha support etc), puts
> > the result in
> > another image and writes that to the destination.  This means that, far
> > from NSCopyBits()
> > being a fast function to shift parts of a view around, it's actually
> > rather slow.
> >
>
>
> Actually it already does this. When the operation is NSCompositeCopy, it
> calls the copyBits:fromRect:toPoint: method. The slow scrolling (in this
> case) is caused in GWorkspace iteself by an unecessary(*) call to
> setNeedsDisplay:
>
> GWorkspace/Viewers/IconsViewer/IconsPanel.m:712
> (gwscrollView:scrollViewScrolled:hitPart:)
>
> (*) I say unecessarily warily as taking this line out exposes some odd
> scrolling bug which causes the display to get messed up when scrolling
> continuously (but gets cleaned up if you just click outside the scroller
> knob).

All the sources of the IconsViewer bundle are the oldest and ugliest code
of GWorkspace, beacause it comes (partially) from one of my first apps,
GFinder.
Probably, there is a better solution for this problem but I've not worked
at the IconsPanel source from about an year. But, if I remember well,
that was the only reasonable solution...
In the revision of all the GWorkspace's sources that I'm doing, I've
left out the IconsViewer because, fundamentally, it needs a complete
rewrite.
But, for this, I'm waiting for resizeable NSImages (don't ask me why
because the explication would be beyond my English :-) )






reply via email to

[Prev in Thread] Current Thread [Next in Thread]