summaryrefslogtreecommitdiffstats
path: root/src/verbs.cpp
diff options
context:
space:
mode:
authorPatrick Storz <eduard.braun2@gmx.de>2019-07-29 19:35:57 +0000
committerPatrick Storz <eduard.braun2@gmx.de>2019-07-29 21:41:28 +0000
commit7d0ce1c2cfd9a7abba80ec8acac9dabf728ded3b (patch)
tree1f36583745bf5401c1a0ef8f00e9208b2f09befc /src/verbs.cpp
parentRemove unneded asignaments (diff)
downloadinkscape-7d0ce1c2cfd9a7abba80ec8acac9dabf728ded3b.tar.gz
inkscape-7d0ce1c2cfd9a7abba80ec8acac9dabf728ded3b.zip
Verbs: Disable SP_VERB_DIALOG_SPELLCHECK when compiling without Aspell
Also avoids showing menu items that have no function. (see also https://gitlab.com/inkscape/inkscape/issues/354)
Diffstat (limited to 'src/verbs.cpp')
-rw-r--r--src/verbs.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/verbs.cpp b/src/verbs.cpp
index 2574ef784..065b7e10c 100644
--- a/src/verbs.cpp
+++ b/src/verbs.cpp
@@ -23,6 +23,10 @@
* Released under GNU GPL v2+, read the file 'COPYING' for more information.
*/
+#ifdef HAVE_CONFIG_H
+# include "config.h" // only include where actually required!
+#endif
+
#include <cstring>
#include <string>
@@ -2189,9 +2193,11 @@ void DialogVerb::perform(SPAction *action, void *data)
case SP_VERB_DIALOG_FIND:
dt->_dlg_mgr->showDialog("Find");
break;
+#if HAVE_ASPELL
case SP_VERB_DIALOG_SPELLCHECK:
dt->_dlg_mgr->showDialog("SpellCheck");
break;
+#endif
case SP_VERB_DIALOG_DEBUG:
dt->_dlg_mgr->showDialog("Messages");
break;
@@ -3110,8 +3116,10 @@ Verb *Verb::_base_verbs[] = {
N_("View and edit selections and CSS styles"), INKSCAPE_ICON("dialog-selectors")),
new DialogVerb(SP_VERB_DIALOG_FIND, "DialogFind", N_("_Find/Replace..."), N_("Find objects in document"),
INKSCAPE_ICON("edit-find")),
+#if HAVE_ASPELL
new DialogVerb(SP_VERB_DIALOG_SPELLCHECK, "DialogSpellcheck", N_("Check Spellin_g..."),
N_("Check spelling of text in document"), INKSCAPE_ICON("tools-check-spelling")),
+#endif
new DialogVerb(SP_VERB_DIALOG_DEBUG, "DialogDebug", N_("_Messages..."), N_("View debug messages"),
INKSCAPE_ICON("dialog-messages")),
new DialogVerb(SP_VERB_DIALOG_TOGGLE, "DialogsToggle", N_("Show/Hide D_ialogs"),