Making kinetic scrolling generic

Aaron J. Seigo aseigo at
Fri Sep 25 18:21:26 CEST 2009

On September 25, 2009, Adenilson Cavalcanti wrote:
> Dear friends
> Last Wednesday, there was a discussion in plasma IRC channel
> concerning ideas to make the Kineticscrolling class more generic to
> handle scrolling in other plasma components.
> Trying to understand how *actual* movement is done in some of
> KDE's plasmoids, I had read the code of following plasmoids:
> 1) Webview (kdelibs/plasma/widgets)
> *WebView class*
>  - object: d->page is a QWebPage
>  - moving: d->page->event(&we);
>  Maybe void QWebPage::scrollRequested ( int dx, int dy, const QRect &
>  rectToScroll )   [signal] could be used or just keep with current approach
>  of generating events.

there's actually some work going on right at Qt to wrap QWebView into a nice 
QGraphicsView object with all kinds of nice things (buffered rendering for 
better scrolling, etc); so i wouldn't worry tooo much about web view right now 
as we'll likely be replacing it with the QGraphicsWebView at some point.

> Trying to address this requirements the following design is proposed:

i like it, especially the use of a standard property.

the only addition would be that such widgets would have to keep that property 
updated with the proper 0..1 value when the contents are scrolled in some 
other way? i assume that KineticScrolling will need this value to determine 
what to do (e.g. the overreach bounce, etc)

> - KineticScrolling emits a signal in setKineticScrollValue

KineticScrolling::setKineticScrollValue is perhaps a little redundant? would 
setScrollValue be enough? either way, it's not a big deal and shouldn't 
interfere with you going ahead with this design in any way.

Aaron J. Seigo
humru othro a kohnu se
GPG Fingerprint: 8B8B 2209 0C6F 7C47 B1EA  EE75 D6B7 2EB1 A7F1 DB43

KDE core developer sponsored by Qt Development Frameworks
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part.
Url : 

More information about the Plasma-devel mailing list