diff options
Diffstat (limited to 'src/pencil-context.cpp')
| -rw-r--r-- | src/pencil-context.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/pencil-context.cpp b/src/pencil-context.cpp index 0a5bc7444..894b5cd71 100644 --- a/src/pencil-context.cpp +++ b/src/pencil-context.cpp @@ -154,8 +154,15 @@ sp_pencil_context_dispose(GObject *object) static void spdc_endpoint_snap(SPPencilContext const *pc, NR::Point &p, guint const state) { - spdc_endpoint_snap_rotation(pc, p, pc->p[0], state); - spdc_endpoint_snap_free(pc, p, state); + if ((state & GDK_CONTROL_MASK)) { //CTRL enables constrained snapping + spdc_endpoint_snap_rotation(pc, p, pc->p[0], state); + } else { + if (!(state & GDK_SHIFT_MASK)) { //SHIFT disables all snapping, except the angular snapping above + //After all, the user explicitely asked for angular snapping by + //pressing CTRL + spdc_endpoint_snap_free(pc, p, state); + } + } } /** |
