diff options
| author | Jabier Arraiza <jabier.arraiza@marker.es> | 2017-07-01 00:35:09 +0000 |
|---|---|---|
| committer | Jabier Arraiza <jabier.arraiza@marker.es> | 2017-07-01 00:35:09 +0000 |
| commit | ff04a08000adfa762ad1f4bc4f4df64c11ed499c (patch) | |
| tree | 9e6f4bcf3c8f87fcecdc8d11dd2eb0ec2d37c0c9 /src/ui/shape-editor.cpp | |
| parent | Merge branch 'master' of https://gitlab.com/jabiertxof/inkscape into selectab... (diff) | |
| download | inkscape-ff04a08000adfa762ad1f4bc4f4df64c11ed499c.tar.gz inkscape-ff04a08000adfa762ad1f4bc4f4df64c11ed499c.zip | |
working on knots selection
Diffstat (limited to 'src/ui/shape-editor.cpp')
| -rw-r--r-- | src/ui/shape-editor.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/ui/shape-editor.cpp b/src/ui/shape-editor.cpp index 98320ed8c..288c6dc5e 100644 --- a/src/ui/shape-editor.cpp +++ b/src/ui/shape-editor.cpp @@ -17,6 +17,8 @@ #include "desktop.h" #include "document.h" #include "knotholder.h" +#include "sp-ellipse.h" +#include "inkscape.h" #include "ui/object-edit.h" #include "ui/shape-editor.h" #include "xml/node-event-vector.h" @@ -81,7 +83,7 @@ const SPItem *ShapeEditor::get_item() { return item; } -void ShapeEditor::event_attr_changed(Inkscape::XML::Node *, gchar const *name, gchar const *, gchar const *, bool, void *data) +void ShapeEditor::event_attr_changed(Inkscape::XML::Node * node, gchar const *name, gchar const *, gchar const *, bool, void *data) { g_assert(data); ShapeEditor *sh = static_cast<ShapeEditor *>(data); @@ -94,7 +96,12 @@ void ShapeEditor::event_attr_changed(Inkscape::XML::Node *, gchar const *name, g if (changed_kh) { // this can happen if an LPEItem's knotholder handle was dragged, in which case we want // to keep the knotholder; in all other cases (e.g., if the LPE itself changes) we delete it - sh->reset_item(!strcmp(name, "d")); + sh->reset_item(!strcmp(name, "d") || + !strcmp(node->name(),"svg:rect") );//|| +// !strcmp(node->name(),"svg:star") || +// !strcmp(node->name(),"svg:spiral") || +// !strcmp(node->name(),"svg:ellipse") || +// SP_IS_GENERICELLIPSE(SP_ACTIVE_DOCUMENT->getObjectById(node->attribute("id")))); } } } |
