[Okular-devel] [PATCH] Panning in Thumbnail List

Albert Astals Cid aacid at kde.org
Thu Nov 5 00:19:19 CET 2009

A Dissabte, 17 d'octubre de 2009, Igor Stirbu va escriure:
> Hello Pino,
> I've worked a bit on the issue in bug #201669. It works now for general
>  case but I'm sure I miss some parts that may break the usability in
>  okular. For example I don't use yet new DocumentViewport instances which I
>  suppose breaks the navigation and I didn't understand exactly if I still
>  need to use
> VisiblePageRect.
> Some of the things I still need to figure out are:
> * when dragging to top or bottom of viewable thumbnails it starts
> to scroll like crazy probably due to some feature of automatically
> show new thumbnails when main view is changed

Yeah this is a problem we should try to fix. I think we could have a variable 
telling if we are changing the viewport because of a drag and if that's 
happening do not do the ensureVisible in notifyViewportChanged, the problem 
with that is that then the view does not scroll when reaching the top/bottom 
"limits" and that's not what the user wants probably. My suggestion here would 
be scrolling the thumbnail view so that the green rectangles always are 

> * the item->rect().size() is not a proper one. I would expect the size
> to be only the preview of the page and not to include the space below
> the preview which contains the page number. If you make the thumbnail
> list wide enough and drag slowly from top to bottom of a thumbnail you
> can see that at the bottom the mouse is not in the middle of the yellow
> rectangle.

I don't see this problem can you attach a screenshot?

Another problem is that you changed the behaviour on how the thumbnail list 
works, the old implementation let's you click anywhere inside the "green area" 
and drag and only moves the viewport the number of pixels you have dragged. 
Your implementation moves the viewport to exactly where you clicked, i think 
this is not what we want.


> Thanks,
> Igor

More information about the Okular-devel mailing list