Code

Tablet auto-organization and naming.
[inkscape.git] / src / display / snap-indicator.cpp
index fe5bd0371927471d2d068a39ea66fe4b18caf769..c3198cd37ea0392724a7b8174d7c4a4a7a6e463c 100644 (file)
@@ -51,7 +51,6 @@ SnapIndicator::set_new_snaptarget(Inkscape::SnappedPoint const &p, bool pre_snap
     g_assert(_desktop != NULL);
 
     if (!p.getSnapped()) {
-        g_warning("No snapping took place, so no snap target will be displayed");
         return; // If we haven't snapped, then it is of no use to draw a snapindicator
     }
 
@@ -229,27 +228,15 @@ SnapIndicator::set_new_snaptarget(Inkscape::SnappedPoint const &p, bool pre_snap
 
         // Display the snap indicator (i.e. the cross)
         SPCanvasItem * canvasitem = NULL;
-        if (p.getTarget() == SNAPTARGET_NODE_SMOOTH || p.getTarget() == SNAPTARGET_NODE_CUSP) {
-            canvasitem = sp_canvas_item_new(sp_desktop_tempgroup (_desktop),
-                                            SP_TYPE_CTRL,
-                                            "anchor", GTK_ANCHOR_CENTER,
-                                            "size", 10.0,
-                                            "stroked", TRUE,
-                                            "stroke_color", pre_snap ? 0x7f7f7fff : 0xff0000ff,
-                                            "mode", SP_KNOT_MODE_XOR,
-                                            "shape", SP_KNOT_SHAPE_DIAMOND,
-                                            NULL );
-        } else {
-            canvasitem = sp_canvas_item_new(sp_desktop_tempgroup (_desktop),
-                                            SP_TYPE_CTRL,
-                                            "anchor", GTK_ANCHOR_CENTER,
-                                            "size", 10.0,
-                                            "stroked", TRUE,
-                                            "stroke_color", pre_snap ? 0x7f7f7fff : 0xff0000ff,
-                                            "mode", SP_KNOT_MODE_XOR,
-                                            "shape", SP_KNOT_SHAPE_CROSS,
-                                            NULL );
-        }
+        canvasitem = sp_canvas_item_new(sp_desktop_tempgroup (_desktop),
+                                        SP_TYPE_CTRL,
+                                        "anchor", GTK_ANCHOR_CENTER,
+                                        "size", 10.0,
+                                        "stroked", TRUE,
+                                        "stroke_color", pre_snap ? 0x7f7f7fff : 0xff0000ff,
+                                        "mode", SP_KNOT_MODE_XOR,
+                                        "shape", SP_KNOT_SHAPE_CROSS,
+                                        NULL );
 
         const int timeout_val = 1200; // TODO add preference for snap indicator timeout?