diff options
| author | Felipe Corr??a da Silva Sanches <juca@members.fsf.org> | 2011-06-06 23:21:21 +0000 |
|---|---|---|
| committer | Felipe C. da S. Sanches <juca@members.fsf.org> | 2011-06-06 23:21:21 +0000 |
| commit | da2a6c9d0f013483a708cad53bb83c0d0766bd69 (patch) | |
| tree | 372b87e9fc196804e27e0ff7b826917e70e1d2e2 /src/tools-switch.cpp | |
| parent | Extensions. Adding i18n support to voronoi2svg.py and interp_att_g.py. New IN... (diff) | |
| download | inkscape-da2a6c9d0f013483a708cad53bb83c0d0766bd69.tar.gz inkscape-da2a6c9d0f013483a708cad53bb83c0d0766bd69.zip | |
Introducing our new nice measurement tool! :-D
(bzr r10259)
Diffstat (limited to 'src/tools-switch.cpp')
| -rw-r--r-- | src/tools-switch.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/tools-switch.cpp b/src/tools-switch.cpp index 1f624cc35..42eaf4474 100644 --- a/src/tools-switch.cpp +++ b/src/tools-switch.cpp @@ -50,6 +50,7 @@ #include "sp-flowtext.h" #include "gradient-context.h" #include "zoom-context.h" +#include "measure-context.h" #include "dropper-context.h" #include "connector-context.h" #include "flood-context.h" @@ -75,6 +76,7 @@ static char const *const tool_names[] = { "/tools/text", "/tools/gradient", "/tools/zoom", + "/tools/measure", "/tools/dropper", "/tools/connector", "/tools/paintbucket", @@ -208,6 +210,12 @@ tools_switch(SPDesktop *dt, int num) inkscape_eventcontext_set(sp_desktop_event_context(dt)); dt->tipsMessageContext()->set(Inkscape::NORMAL_MESSAGE, _("<b>Click</b> or <b>drag around an area</b> to zoom in, <b>Shift+click</b> to zoom out.")); break; + case TOOLS_MEASURE: + dt->set_event_context(SP_TYPE_MEASURE_CONTEXT, tool_names[num]); + dt->activate_guides(false); + inkscape_eventcontext_set(sp_desktop_event_context(dt)); + dt->tipsMessageContext()->set(Inkscape::NORMAL_MESSAGE, _("<b>Drag</b> to measure the dimensions of objects.")); + break; case TOOLS_DROPPER: dt->set_event_context(SP_TYPE_DROPPER_CONTEXT, tool_names[num]); dt->activate_guides(false); |
