summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: d4200d9)
raw | patch | inline | side by side (parent: d4200d9)
author | johanengelen <johanengelen@users.sourceforge.net> | |
Fri, 1 Aug 2008 17:45:13 +0000 (17:45 +0000) | ||
committer | johanengelen <johanengelen@users.sourceforge.net> | |
Fri, 1 Aug 2008 17:45:13 +0000 (17:45 +0000) |
12 files changed:
index 3d109a69c0ccdd328cc32beb837852c913a3c9df..1a77008f1cb2ab7236d2fa7f5a0540b5fdcd5ae3 100644 (file)
NR::Maybe<NR::Rect> bbox = sp_item_bbox_desktop(cc->active_shape);
if (bbox) {
NR::Point center = bbox->midpoint();
- sp_knot_set_position(cc->connpthandle, ¢er, 0);
+ sp_knot_set_position(cc->connpthandle, center, 0);
sp_knot_show(cc->connpthandle);
} else {
sp_knot_hide(cc->connpthandle);
{
// Just adjust handle positions.
NR::Point startpt = curve->first_point() * i2d;
- sp_knot_set_position(cc->endpt_handle[0], &startpt, 0);
+ sp_knot_set_position(cc->endpt_handle[0], startpt, 0);
NR::Point endpt = curve->last_point() * i2d;
- sp_knot_set_position(cc->endpt_handle[1], &endpt, 0);
+ sp_knot_set_position(cc->endpt_handle[1], endpt, 0);
return;
}
}
NR::Point startpt = curve->first_point() * i2d;
- sp_knot_set_position(cc->endpt_handle[0], &startpt, 0);
+ sp_knot_set_position(cc->endpt_handle[0], startpt, 0);
NR::Point endpt = curve->last_point() * i2d;
- sp_knot_set_position(cc->endpt_handle[1], &endpt, 0);
+ sp_knot_set_position(cc->endpt_handle[1], endpt, 0);
sp_knot_show(cc->endpt_handle[0]);
sp_knot_show(cc->endpt_handle[1]);
diff --git a/src/gradient-drag.cpp b/src/gradient-drag.cpp
index 7489f9451531f7a38a5dd11195607691391a9450..71b71b1c3c0fda3daa08def877b2b8fe14817532 100644 (file)
--- a/src/gradient-drag.cpp
+++ b/src/gradient-drag.cpp
@@ -584,7 +584,7 @@ gr_knot_moved_handler(SPKnot *knot, NR::Point const *ppointer, guint state, gpoi
Inkscape::SnappedPoint s = m.freeSnap(Inkscape::Snapper::SNAPPOINT_NODE, p);
if (s.getSnapped()) {
p = s.getPoint();
- sp_knot_moveto (knot, &p);
+ sp_knot_moveto (knot, p);
} else {
bool was_snapped = false;
double dist = NR_HUGE;
@@ -595,7 +595,7 @@ gr_knot_moved_handler(SPKnot *knot, NR::Point const *ppointer, guint state, gpoi
p[NR::Y] = dragger->parent->hor_levels[i];
s = Inkscape::SnappedPoint(p, Inkscape::SNAPTARGET_GRADIENT, dist, snap_dist, false);
was_snapped = true;
- sp_knot_moveto (knot, &p);
+ sp_knot_moveto (knot, p);
}
}
for (guint i = 0; i < dragger->parent->vert_levels.size(); i++) {
@@ -604,7 +604,7 @@ gr_knot_moved_handler(SPKnot *knot, NR::Point const *ppointer, guint state, gpoi
p[NR::X] = dragger->parent->vert_levels[i];
s = Inkscape::SnappedPoint(p, Inkscape::SNAPTARGET_GRADIENT, dist, snap_dist, false);
was_snapped = true;
- sp_knot_moveto (knot, &p);
+ sp_knot_moveto (knot, p);
}
}
if (was_snapped) {
@@ -685,7 +685,7 @@ gr_knot_moved_handler(SPKnot *knot, NR::Point const *ppointer, guint state, gpoi
}
if (move[NR::X] < 9999) {
p += move;
- sp_knot_moveto (knot, &p);
+ sp_knot_moveto (knot, p);
}
g_slist_free(snap_vectors);
@@ -837,7 +837,7 @@ gr_knot_moved_midpoint_handler(SPKnot */*knot*/, NR::Point const *ppointer, guin
}
}
drg->point += this_move;
- sp_knot_moveto (drgknot, & drg->point);
+ sp_knot_moveto (drgknot, drg->point);
drg->fireDraggables (false);
drg->updateDependencies(false);
}
@@ -1168,7 +1168,7 @@ GrDragger::moveThisToDraggable (SPItem *item, gint point_type, gint point_i, boo
this->point = sp_item_gradient_get_coords (item, point_type, point_i, fill_or_stroke);
this->point_original = this->point;
- sp_knot_moveto (this->knot, &(this->point));
+ sp_knot_moveto (this->knot, this->point);
for (GSList const* i = this->draggables; i != NULL; i = i->next) {
GrDraggable *da = (GrDraggable *) i->data;
sp_knot_update_ctrl(this->knot);
// move knot to the given point
- sp_knot_set_position (this->knot, &p, SP_KNOT_STATE_NORMAL);
+ sp_knot_set_position (this->knot, p, SP_KNOT_STATE_NORMAL);
sp_knot_show (this->knot);
// connect knot's signals
@@ -1792,7 +1792,7 @@ GrDrag::selected_move (double x, double y, bool write_repr, bool scale_radial)
did = true;
d->point += NR::Point (x, y);
d->point_original = d->point;
- sp_knot_moveto (d->knot, &(d->point));
+ sp_knot_moveto (d->knot, d->point);
d->fireDraggables (write_repr, scale_radial);
@@ -1828,7 +1828,7 @@ GrDrag::selected_move (double x, double y, bool write_repr, bool scale_radial)
GrDragger *drg = (GrDragger*) i->data;
SPKnot *drgknot = drg->knot;
drg->point += displacement;
- sp_knot_moveto (drgknot, & drg->point);
+ sp_knot_moveto (drgknot, drg->point);
drg->fireDraggables (true);
drg->updateDependencies(true);
did = true;
index 3c95bb0b4651c5005ed06f2370c22205d0e3203a..d40fd735aceeaab314d1fa2a4a6db5801d217c14 100644 (file)
NR::Point dp(knot_get() * i2d);
_moved_connection.block();
- sp_knot_set_position(knot, &dp, SP_KNOT_STATE_NORMAL);
+ sp_knot_set_position(knot, dp, SP_KNOT_STATE_NORMAL);
_moved_connection.unblock();
}
diff --git a/src/knot.cpp b/src/knot.cpp
index 7e4a3dd25f331b901ee17914e0cc2a5cab7411f3..1584769b4613b98669e1f24da01f8d759f2cfe83 100644 (file)
--- a/src/knot.cpp
+++ b/src/knot.cpp
knot->flags = 0;
knot->size = 8;
- knot->pos = NR::Point(0, 0);
- knot->grabbed_rel_pos = NR::Point(0, 0);
+ knot->pos = Geom::Point(0, 0);
+ knot->grabbed_rel_pos = Geom::Point(0, 0);
knot->anchor = GTK_ANCHOR_CENTER;
knot->shape = SP_KNOT_SHAPE_SQUARE;
knot->mode = SP_KNOT_MODE_XOR;
/**
* Update knot for dragging and tell canvas an item was grabbed.
*/
-void sp_knot_start_dragging(SPKnot *knot, NR::Point p, gint x, gint y, guint32 etime)
+void sp_knot_start_dragging(SPKnot *knot, Geom::Point const &p, gint x, gint y, guint32 etime)
{
// save drag origin
xp = x;
@@ -313,7 +313,7 @@ static int sp_knot_handler(SPCanvasItem */*item*/, GdkEvent *event, SPKnot *knot
break;
case GDK_BUTTON_PRESS:
if (event->button.button == 1 && !knot->desktop->event_context->space_panning) {
- NR::Point const p = knot->desktop->w2d(NR::Point(event->button.x, event->button.y));
+ Geom::Point const p = knot->desktop->w2d(Geom::Point(event->button.x, event->button.y));
sp_knot_start_dragging(knot, p, (gint) event->button.x, (gint) event->button.y, event->button.time);
consumed = TRUE;
}
@@ -377,10 +377,10 @@ static int sp_knot_handler(SPCanvasItem */*item*/, GdkEvent *event, SPKnot *knot
SP_KNOT_DRAGGING,
TRUE);
}
- NR::Point const motion_w(event->motion.x, event->motion.y);
+ Geom::Point const motion_w(event->motion.x, event->motion.y);
NR::Point const motion_dt = knot->desktop->w2d(motion_w);
- NR::Point p = motion_dt - knot->grabbed_rel_pos;
- sp_knot_request_position (knot, &p, event->motion.state);
+ Geom::Point p = motion_dt - knot->grabbed_rel_pos;
+ sp_knot_request_position (knot, p, event->motion.state);
knot->desktop->scroll_to_point (&motion_dt);
knot->desktop->set_coordinate_status(knot->pos); // display the coordinate of knot, not cursor - they may be different!
if (event->motion.state & GDK_BUTTON1_MASK)
/**
* Request or set new position for knot.
*/
-void sp_knot_request_position(SPKnot *knot, NR::Point *p, guint state)
+void sp_knot_request_position(SPKnot *knot, Geom::Point const &p, guint state)
{
g_return_if_fail(knot != NULL);
g_return_if_fail(SP_IS_KNOT(knot));
g_signal_emit(knot,
knot_signals[REQUEST], 0,
- p,
+ &p,
state,
&done);
/**
* Return distance of point to knot's position; unused.
*/
-gdouble sp_knot_distance(SPKnot * knot, NR::Point *p, guint state)
+gdouble sp_knot_distance(SPKnot * knot, Geom::Point const &p, guint state)
{
g_return_val_if_fail(knot != NULL, 1e18);
g_return_val_if_fail(SP_IS_KNOT(knot), 1e18);
- gdouble distance = NR::L2(*p - knot->pos);
+ gdouble distance = Geom::L2(p - knot->pos);
g_signal_emit(knot,
knot_signals[DISTANCE], 0,
- p,
+ &p,
state,
&distance);
/**
* Move knot to new position.
*/
-void sp_knot_set_position(SPKnot *knot, NR::Point *p, guint state)
+void sp_knot_set_position(SPKnot *knot, Geom::Point const &p, guint state)
{
g_return_if_fail(knot != NULL);
g_return_if_fail(SP_IS_KNOT (knot));
- knot->pos = *p;
+ knot->pos = p;
if (knot->item) {
- SP_CTRL(knot->item)->moveto (*p);
+ SP_CTRL(knot->item)->moveto (p);
}
g_signal_emit(knot,
knot_signals[MOVED], 0,
- p,
+ &p,
state);
knot->_moved_signal.emit(knot, p, state);
}
/**
* Move knot to new position, without emitting a MOVED signal.
*/
-void sp_knot_moveto(SPKnot *knot, NR::Point *p)
+void sp_knot_moveto(SPKnot *knot, Geom::Point const &p)
{
g_return_if_fail(knot != NULL);
g_return_if_fail(SP_IS_KNOT(knot));
- knot->pos = *p;
+ knot->pos = p;
if (knot->item) {
- SP_CTRL(knot->item)->moveto (*p);
+ SP_CTRL(knot->item)->moveto (p);
}
}
/**
* Returns position of knot.
*/
-NR::Point sp_knot_position(SPKnot const *knot)
+Geom::Point sp_knot_position(SPKnot const *knot)
{
g_assert(knot != NULL);
g_assert(SP_IS_KNOT (knot));
diff --git a/src/knot.h b/src/knot.h
index b1505daacbec3b7a31447d6e4cfa378c52d12833..07c2640c3b563767b8173835ea99571c0f5b44d0 100644 (file)
--- a/src/knot.h
+++ b/src/knot.h
#include <gtk/gtkenums.h>
#include "display/display-forward.h"
#include "forward.h"
-#include <libnr/nr-point.h>
+#include <2geom/point.h>
#include "knot-enums.h"
#include <sigc++/sigc++.h>
guint flags;
guint size; /**< Always square. */
- NR::Point pos; /**< Our desktop coordinates. */
- NR::Point grabbed_rel_pos; /**< Grabbed relative position. */
- NR::Point drag_origin; /**< Origin of drag. */
+ Geom::Point pos; /**< Our desktop coordinates. */
+ Geom::Point grabbed_rel_pos; /**< Grabbed relative position. */
+ Geom::Point drag_origin; /**< Origin of drag. */
GtkAnchorType anchor; /**< Anchor. */
SPKnotShapeType shape; /**< Shape type. */
// C++ signals
/**
- sigc::signal<void, NR::Point const &, NR::Point const &, guint> _moved_signal;
+ sigc::signal<void, Geom::Point const &, Geom::Point const &, guint> _moved_signal;
sigc::signal<void, guint> _click_signal;
- sigc::signal<NR::Point> _ungrabbed_signal;
+ sigc::signal<Geom::Point> _ungrabbed_signal;
**/
- sigc::signal<void, SPKnot *, NR::Point const *, guint> _moved_signal;
+ sigc::signal<void, SPKnot *, Geom::Point const &, guint> _moved_signal;
sigc::signal<void, SPKnot *, guint> _click_signal;
sigc::signal<void, SPKnot *> _ungrabbed_signal;
void (* doubleclicked) (SPKnot *knot, guint state);
void (* grabbed) (SPKnot *knot, guint state);
void (* ungrabbed) (SPKnot *knot, guint state);
- void (* moved) (SPKnot *knot, NR::Point *position, guint state);
+ void (* moved) (SPKnot *knot, Geom::Point const &position, guint state);
void (* stamped) (SPKnot *know, guint state);
/** Request knot to move to absolute position. */
- bool (* request) (SPKnot *knot, NR::Point *pos, guint state);
+ bool (* request) (SPKnot *knot, Geom::Point const &pos, guint state);
/** Find complex distance from knot to point. */
- gdouble (* distance) (SPKnot *knot, NR::Point *pos, guint state);
+ gdouble (* distance) (SPKnot *knot, Geom::Point const &pos, guint state);
};
GType sp_knot_get_type();
void sp_knot_set_flag(SPKnot *knot, guint flag, bool set);
void sp_knot_update_ctrl(SPKnot *knot);
-void sp_knot_request_position(SPKnot *knot, NR::Point *pos, guint state);
-gdouble sp_knot_distance(SPKnot *knot, NR::Point *p, guint state);
+void sp_knot_request_position(SPKnot *knot, Geom::Point const &pos, guint state);
+gdouble sp_knot_distance(SPKnot *knot, Geom::Point const &p, guint state);
-void sp_knot_start_dragging(SPKnot *knot, NR::Point p, gint x, gint y, guint32 etime);
+void sp_knot_start_dragging(SPKnot *knot, Geom::Point const &p, gint x, gint y, guint32 etime);
/** Moves knot and emits "moved" signal. */
-void sp_knot_set_position(SPKnot *knot, NR::Point *p, guint state);
+void sp_knot_set_position(SPKnot *knot, Geom::Point const &p, guint state);
/** Moves knot without any signal. */
-void sp_knot_moveto(SPKnot *knot, NR::Point *p);
+void sp_knot_moveto(SPKnot *knot, Geom::Point const &p);
-NR::Point sp_knot_position(SPKnot const *knot);
+Geom::Point sp_knot_position(SPKnot const *knot);
#endif /* !__SP_KNOT_H__ */
diff --git a/src/knotholder.cpp b/src/knotholder.cpp
index df50b9ff520bbd2874ff6a209686d45cacedf5f2..629aa73684a3924d3202912261a7bf929631dc24 100644 (file)
--- a/src/knotholder.cpp
+++ b/src/knotholder.cpp
}
void
-KnotHolder::knot_moved_handler(SPKnot *knot, NR::Point const *p, guint state)
+KnotHolder::knot_moved_handler(SPKnot *knot, Geom::Point const &p, guint state)
{
// this was a local change and the knotholder does not need to be recreated:
this->local_change = TRUE;
for(std::list<KnotHolderEntity *>::iterator i = this->entity.begin(); i != this->entity.end(); ++i) {
KnotHolderEntity *e = *i;
if (e->knot == knot) {
- NR::Point const q = *p / from_2geom(sp_item_i2d_affine(item));
+ NR::Point const q = p / from_2geom(sp_item_i2d_affine(item));
e->knot_set(q, e->knot->drag_origin / from_2geom(sp_item_i2d_affine(item)), state);
break;
}
diff --git a/src/knotholder.h b/src/knotholder.h
index bd57776dbfd4066650b2d9e4f8f8743e6efe5e23..6b838b3c9bd84e2db8ab9af6959ac01db72cfb4a 100644 (file)
--- a/src/knotholder.h
+++ b/src/knotholder.h
#include "knot-enums.h"
#include "forward.h"
#include "libnr/nr-forward.h"
+#include <2geom/forward.h>
#include "knot-holder-entity.h"
#include <list>
void update_knots();
- void knot_moved_handler(SPKnot *knot, NR::Point const *p, guint state);
+ void knot_moved_handler(SPKnot *knot, Geom::Point const &p, guint state);
void knot_clicked_handler(SPKnot *knot, guint state);
void knot_ungrabbed_handler(SPKnot *knot);
diff --git a/src/live_effects/parameter/pointparam-knotholder.cpp b/src/live_effects/parameter/pointparam-knotholder.cpp
index d92532e327a16ac4d9f2401c30b6d7c0ea139ae9..42601c170b8fa27f8130085bfe84560007e9bc8d 100644 (file)
// Move to current point.
NR::Point dp = p * from_2geom(sp_item_i2d_affine(item));
- sp_knot_set_position(e->knot, &dp, SP_KNOT_STATE_NORMAL);
+ sp_knot_set_position(e->knot, dp, SP_KNOT_STATE_NORMAL);
e->handler_id = g_signal_connect(e->knot, "moved", G_CALLBACK(pointparam_knot_moved_handler), this);
e->_click_handler_id = g_signal_connect(e->knot, "clicked", G_CALLBACK(pointparam_knot_clicked_handler), this);
diff --git a/src/nodepath.cpp b/src/nodepath.cpp
index 337731e5742dd3668837f097d056bb05b4760850..ec99208152d25e69f2042caabbdfb47b5843631e 100644 (file)
--- a/src/nodepath.cpp
+++ b/src/nodepath.cpp
@@ -1705,11 +1705,11 @@ static void sp_node_update_handle(Inkscape::NodePath::Node *node, gint which, gb
sp_ctrlline_set_coords(SP_CTRLLINE(side->line), node->pos, side->pos);
sp_knot_show(side->knot);
} else {
- if (side->knot->pos != side->pos) { // only if it's really moved
+ if (side->knot->pos != to_2geom(side->pos)) { // only if it's really moved
if (fire_move_signals) {
- sp_knot_set_position(side->knot, &side->pos, 0); // this will set coords of the line as well
+ sp_knot_set_position(side->knot, side->pos, 0); // this will set coords of the line as well
} else {
- sp_knot_moveto(side->knot, &side->pos);
+ sp_knot_moveto(side->knot, side->pos);
sp_ctrlline_set_coords(SP_CTRLLINE(side->line), node->pos, side->pos);
}
}
@@ -1744,11 +1744,11 @@ static void sp_node_update_handles(Inkscape::NodePath::Node *node, bool fire_mov
sp_knot_show(node->knot);
}
- if (node->knot->pos != node->pos) { // visible knot is in a different position, need to update
+ if (node->knot->pos != to_2geom(node->pos)) { // visible knot is in a different position, need to update
if (fire_move_signals)
- sp_knot_set_position(node->knot, &node->pos, 0);
+ sp_knot_set_position(node->knot, node->pos, 0);
else
- sp_knot_moveto(node->knot, &node->pos);
+ sp_knot_moveto(node->knot, node->pos);
}
gboolean show_handles = node->selected;
// forget origin and set knot position once more (because it can be wrong now due to restrictions)
if (n->p.knot == knot) {
n->p.origin_radial.a = 0;
- sp_knot_set_position(knot, &n->p.pos, state);
+ sp_knot_set_position(knot, n->p.pos, state);
} else if (n->n.knot == knot) {
n->n.origin_radial.a = 0;
- sp_knot_set_position(knot, &n->n.pos, state);
+ sp_knot_set_position(knot, n->n.pos, state);
} else {
g_assert_not_reached();
}
@@ -3916,7 +3916,7 @@ static void node_handle_moved(SPKnot *knot, NR::Point *p, guint state, gpointer
other->pos = NR::Point(rother) + n->pos;
if (other->knot) {
sp_ctrlline_set_coords(SP_CTRLLINE(other->line), n->pos, other->pos);
- sp_knot_moveto(other->knot, &other->pos);
+ sp_knot_moveto(other->knot, other->pos);
}
}
@@ -3925,7 +3925,7 @@ static void node_handle_moved(SPKnot *knot, NR::Point *p, guint state, gpointer
// move knot, but without emitting the signal:
// we cannot emit a "moved" signal because we're now processing it
- sp_knot_moveto(me->knot, &(me->pos));
+ sp_knot_moveto(me->knot, me->pos);
update_object(n->subpath->nodepath);
@@ -4485,7 +4485,7 @@ sp_nodepath_node_new(Inkscape::NodePath::SubPath *sp, Inkscape::NodePath::Node *
n->n.other = next;
n->knot = sp_knot_new(sp->nodepath->desktop, _("<b>Node</b>: drag to edit the path; with <b>Ctrl</b> to snap to horizontal/vertical; with <b>Ctrl+Alt</b> to snap to handles' directions"));
- sp_knot_set_position(n->knot, pos, 0);
+ sp_knot_set_position(n->knot, *pos, 0);
n->knot->setShape ((n->type == Inkscape::NodePath::NODE_CUSP)? SP_KNOT_SHAPE_DIAMOND : SP_KNOT_SHAPE_SQUARE);
n->knot->setSize ((n->type == Inkscape::NodePath::NODE_CUSP)? 9 : 7);
diff --git a/src/proj_pt.h b/src/proj_pt.h
index f27719c83710cfc898a72b2fd733ffa879512cea..b14dea50e3b73fcfeab0b0168ee29abaa7508bd1 100644 (file)
--- a/src/proj_pt.h
+++ b/src/proj_pt.h
* Released under GNU GPL, read the file 'COPYING' for more information
*/
+#include <2geom/point.h>
#include "libnr/nr-point.h"
#include "libnr/nr-values.h"
#include <gtk/gtk.h>
Pt2 () { pt[0] = 0; pt[1] = 0; pt[2] = 1.0; } // we default to (0 : 0 : 1)
Pt2 (double x, double y, double w) { pt[0] = x; pt[1] = y; pt[2] = w; }
Pt2 (NR::Point const &point) { pt[0] = point[NR::X]; pt[1] = point[NR::Y]; pt[2] = 1; }
+ Pt2 (Geom::Point const &point) { pt[0] = point[Geom::X]; pt[1] = point[Geom::Y]; pt[2] = 1; }
Pt2 (const gchar *coord_str);
inline double operator[] (unsigned int index) const {
diff --git a/src/seltrans.cpp b/src/seltrans.cpp
index a3e0c9f0b4cec86f897f6c5439acd7542c4389b5..c478036c7eccbdbb1097a7b7b58077fa6d9c4ae4 100644 (file)
--- a/src/seltrans.cpp
+++ b/src/seltrans.cpp
sp_knot_hide(_chandle);
} else {
sp_knot_show(_chandle);
- sp_knot_moveto(_chandle, &*_center);
+ sp_knot_moveto(_chandle, *_center);
}
}
@@ -681,7 +681,7 @@ void Inkscape::SelTrans::_showHandles(SPKnot *knot[], SPSelTransHandle const han
+ ( _bbox->dimensions()
* NR::scale(handle_pt) ) );
- sp_knot_moveto(knot[i], &p);
+ sp_knot_moveto(knot[i], p);
}
}
@@ -807,7 +807,7 @@ gboolean Inkscape::SelTrans::handleRequest(SPKnot *knot, NR::Point *position, gu
return TRUE;
}
if (handle.request(this, handle, *position, state)) {
- sp_knot_set_position(knot, position, state);
+ sp_knot_set_position(knot, *position, state);
SP_CTRL(_grip)->moveto(*position);
SP_CTRL(_norm)->moveto(_origin);
}
index 9688b8501b4189a106d08ff3dcd616d6a3762ea9..dcf8d6e71ee0f99bf95671c4f2c7d663da0f8660 100644 (file)
--- a/src/vanishing-point.cpp
+++ b/src/vanishing-point.cpp
sp_knot_update_ctrl(this->knot);
// move knot to the given point
- sp_knot_set_position (this->knot, &this->point, SP_KNOT_STATE_NORMAL);
+ sp_knot_set_position (this->knot, this->point, SP_KNOT_STATE_NORMAL);
sp_knot_show (this->knot);
// connect knot's signals