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 785758 - libview: Fix debug borders coordinate translation
libview: Fix debug borders coordinate translation
Status: RESOLVED FIXED
Product: evince
Classification: Core
Component: general
git master
Other All
: Normal normal
: ---
Assigned To: Evince Maintainers
Evince Maintainers
Depends on:
Blocks:
 
 
Reported: 2017-08-03 07:35 UTC by astian
Modified: 2017-08-05 06:45 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
libview: Fix debug borders coordinate translation (2.51 KB, patch)
2017-08-03 07:35 UTC, astian
none Details | Review
libview: Fix debug borders coordinate translation (2.56 KB, patch)
2017-08-03 15:03 UTC, astian
committed Details | Review

Description astian 2017-08-03 07:35:02 UTC
Created attachment 356820 [details] [review]
libview: Fix debug borders coordinate translation

This commit fixes two bugs in the drawing of borders for "text
selection" bounding boxes:

  1. Borders in document coordinates were being clipped using view
     coordinates.

  2. The document-to-view coordinate translation didn't take view
     rotation into account.
Comment 1 astian 2017-08-03 15:03:10 UTC
Created attachment 356857 [details] [review]
libview: Fix debug borders coordinate translation
Comment 2 Carlos Garcia Campos 2017-08-05 06:32:02 UTC
Review of attachment 356857 [details] [review]:

::: libview/ev-view.c
@@ +4535,3 @@
+		 *
+		 * TODO: Can't we just change the _get_text_mapping API so
+		 * that it matches the other _get_*_mapping APIs?

This is because tyext mapping is represented by a cairo region that uses cairo_rectangle_int_t.
Comment 3 Carlos Garcia Campos 2017-08-05 06:44:55 UTC
Comment on attachment 356857 [details] [review]
libview: Fix debug borders coordinate translation

Pushed without the comment, thanks!