After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 702406 - Dragging selected text fails when zoomed
Dragging selected text fails when zoomed
Status: RESOLVED FIXED
Product: evince
Classification: Core
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Evince Maintainers
Evince Maintainers
Depends on:
Blocks:
 
 
Reported: 2013-06-16 16:42 UTC by Jason Crain
Modified: 2013-06-18 08:35 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Use EvPixbufCache to find selection region (1.65 KB, patch)
2013-06-16 16:42 UTC, Jason Crain
none Details | Review
Use EvPixbufCache to find selection region (1.64 KB, patch)
2013-06-18 04:31 UTC, Jason Crain
committed Details | Review

Description Jason Crain 2013-06-16 16:42:45 UTC
Created attachment 246974 [details] [review]
Use EvPixbufCache to find selection region

Evince has the ability to drag and drop text to somewhere else.  It works mostly like copy and paste.  Select some text, and drag and drop the selection to a text editor or some other program.

But it doesn't work if you select some text and then zoom in or out.  To reproduce, select some text (more obvious if you select just a few words), zoom in or out, and then try to drag and drop the selected text.  Most likely it will just change which text is selected instead of starting a drag.

It's because EvView doesn't update the selection region when the zoom changes.  When you zoom, the location_in_selected_text function thinks the selection region is somewhere else.  This patch patch changes it to use the more reliable ev_pixbuf_cache_get_selection_surface function to find the selection region.

This may depend on bug 669022, as the ev_pixbuf_cache_get_selection_surface function may change.
Comment 1 Jason Crain 2013-06-18 04:31:13 UTC
Created attachment 247084 [details] [review]
Use EvPixbufCache to find selection region

Attached patch is updated to use new function ev_pixbuf_cache_get_selection_region.
Comment 2 Carlos Garcia Campos 2013-06-18 08:35:39 UTC
Review of attachment 247084 [details] [review]:

Good catch, pushed to git master. Thanks!