Bug 266537 - Rectangle selection tool may leave behind visual artifacts on pages
Summary: Rectangle selection tool may leave behind visual artifacts on pages
Status: RESOLVED FIXED
Alias: None
Product: okular
Classification: Applications
Component: general (show other bugs)
Version: 0.19.60
Platform: Unlisted Binaries Linux
: NOR normal
Target Milestone: ---
Assignee: Okular developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-02-17 17:12 UTC by Eike Hein
Modified: 2017-02-08 22:17 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Notice the line artifact above the selection rectangle in this screenshot. (366 bytes, image/png)
2011-02-17 17:12 UTC, Eike Hein
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Eike Hein 2011-02-17 17:12:52 UTC
Created attachment 57331 [details]
Notice the line artifact above the selection rectangle in this screenshot.

The affected Okular version reports itself as 0.11.2, but is a recent SVN checkout of trunk.

The rectangle selection tool leaves behind visual artifacts on pages after a particular sequence of user inputs. In the following rundown, pay special attention to the "slowly" directive in step #3 that seems to be necessary to reproducing the bug:

1. Ctrl+3 to enable the tool.
2. Drag a rectangle right- and upward from the initial mouse cursor position that becomes the selection anchor.
3. Keeping left mouse firmly pressed, *slowly* move the pointer straight downward until the height coordinate of the cursor position is below the height coordinate of the selection anchor by a good distance, i.e. in some sense turning the selection rectangle created in step #2 over vertically.

The result of step #3 is that a visual artifact in the shape of a line spanning the width of the selection rectangle gets left behind just above the rectangle. When releasing the mouse, the selection rectangle disappears, but the artifact is left behind. It also stays in place when moving the document inside the viewport.

The artifact can be wiped from the page by drawing a new selection rectangle that covers it fully and then releasing the mouse.

The attached screenshot shows the artifact above the selection rectangle just before releasing the mouse.
Comment 1 Albert Astals Cid 2012-08-09 22:26:00 UTC
Can you still reproduce this in newer okular versions?
Comment 2 Eike Hein 2012-08-10 19:18:28 UTC
Yes.
Comment 3 Albert Astals Cid 2012-08-10 20:36:25 UTC
Right, i can see it now too.
Comment 4 Walter Mollica 2017-02-07 21:25:11 UTC
Patch posted for review: https://phabricator.kde.org/D4487
Comment 5 Albert Astals Cid 2017-02-08 22:17:37 UTC
Git commit 6f3970dbe48fb6b75c611ea68994e57a98791a47 by Albert Astals Cid, on behalf of Walter Mollica.
Committed on 08/02/2017 at 22:16.
Pushed by aacid into branch 'Applications/16.12'.

Extend viewport update area when updating or clearing the a selection rectangle

Extending the viewport update area of the selection rectangle when dragging the mouse while in selection mode or when canceling the selection ensures that no artifacts remain on-screen in either case.

Differential Revision: https://phabricator.kde.org/D4487

M  +2    -2    ui/pageview.cpp

https://commits.kde.org/okular/6f3970dbe48fb6b75c611ea68994e57a98791a47