From 326274fb56d7bcef5cb09e74b7b9ece9c079e8cc Mon Sep 17 00:00:00 2001 From: gouldtj Date: Thu, 1 Mar 2007 07:13:50 +0000 Subject: [PATCH] r14577@tres: ted | 2007-02-27 18:51:05 -0800 Filling in the list function to list all the verbs for the command line option --verb-list --- src/verbs.cpp | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/src/verbs.cpp b/src/verbs.cpp index 36884f37b..1627f42bf 100644 --- a/src/verbs.cpp +++ b/src/verbs.cpp @@ -2406,8 +2406,19 @@ Verb *Verb::_base_verbs[] = { void Verb::list (void) { - printf("Listing Verbs\n"); + // Go through the dynamic verb table + for (VerbTable::iterator iter = _verbs.begin(); iter != _verbs.end(); iter++) { + Verb * verb = iter->second; + if (verb->get_code() == SP_VERB_INVALID || + verb->get_code() == SP_VERB_NONE || + verb->get_code() == SP_VERB_LAST) { + continue; + } + + printf("\"%s\", \"%s\"\n", verb->get_id(), verb->get_name()); + } + return; }; } /* namespace Inkscape */ -- 2.30.2