From: dvlierop2 Date: Thu, 2 Apr 2009 19:35:48 +0000 (+0000) Subject: Whether we drag a guide's origin or rotate the guide around its origin is now indepen... X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=cedead99dd5eab3aea7d8f23cc2dd97b041c1793;p=inkscape.git Whether we drag a guide's origin or rotate the guide around its origin is now independent of zoom --- diff --git a/src/desktop-events.cpp b/src/desktop-events.cpp index 47b97e3bc..3d8e88fba 100644 --- a/src/desktop-events.cpp +++ b/src/desktop-events.cpp @@ -268,7 +268,7 @@ gint sp_dt_guide_event(SPCanvasItem *item, GdkEvent *event, gpointer data) } sp_event_context_snap_window_open(desktop->event_context); - double tol = 40.0; + double tol = 40.0; // Measured in screenpixels Geom::Point const event_w(event->button.x, event->button.y); Geom::Point const event_dt(desktop->w2d(event_w)); @@ -279,7 +279,7 @@ gint sp_dt_guide_event(SPCanvasItem *item, GdkEvent *event, gpointer data) // https://bugs.launchpad.net/inkscape/+bug/333762 drag_origin = Geom::projection(event_dt, Geom::Line(guide->point_on_line, guide->angle())); - if (Geom::L2(guide->point_on_line - event_dt) < tol) { + if (Geom::L2(guide->point_on_line - event_dt) < tol/desktop->current_zoom()) { // the click was on the guide 'anchor' drag_type = (event->button.state & GDK_SHIFT_MASK) ? SP_DRAG_MOVE_ORIGIN : SP_DRAG_TRANSLATE; } else {