From: buliabyak Date: Fri, 12 Oct 2007 05:38:02 +0000 (+0000) Subject: scroll desktop to selected node after Tab/Shift-Tab X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=453ab85aacd945bf49ff1a7b51bb5ec1569de568;p=inkscape.git scroll desktop to selected node after Tab/Shift-Tab --- diff --git a/src/shape-editor.cpp b/src/shape-editor.cpp index d9a500e3c..f029aab0a 100644 --- a/src/shape-editor.cpp +++ b/src/shape-editor.cpp @@ -442,12 +442,20 @@ void ShapeEditor::select_all_from_subpath (bool invert) { sp_nodepath_select_all_from_subpath (this->nodepath, invert); } void ShapeEditor::select_next () { - if (this->nodepath) + if (this->nodepath) { sp_nodepath_select_next (this->nodepath); + if (this->nodepath->numSelected() >= 1) { + this->desktop->scroll_to_point(&(this->nodepath->singleSelectedCoords()), 1.0); + } + } } void ShapeEditor::select_prev () { - if (this->nodepath) + if (this->nodepath) { sp_nodepath_select_prev (this->nodepath); + if (this->nodepath->numSelected() >= 1) { + this->desktop->scroll_to_point(&(this->nodepath->singleSelectedCoords()), 1.0); + } + } } void ShapeEditor::show_handles (bool show) {