From fdb68963cec5ddbd3eef111f4c95b7e049aa839c Mon Sep 17 00:00:00 2001 From: Slagvi Public Date: Tue, 2 Jul 2013 17:37:42 +0200 Subject: Adding NewFromTemplate to the Inkscape menu (bzr r12379.2.5) --- src/file.h | 1 + src/menus-skeleton.h | 1 + src/templates/new-from-template.cpp | 42 ----------- src/templates/new-from-template.h | 31 --------- src/templates/static-template-load-tab.cpp | 47 ------------- src/templates/static-template-load-tab.h | 33 --------- src/templates/template-load-tab.cpp | 107 ----------------------------- src/templates/template-load-tab.h | 59 ---------------- src/ui/dialog/Makefile_insert | 6 ++ src/ui/dialog/new-from-template.cpp | 42 +++++++++++ src/ui/dialog/new-from-template.h | 31 +++++++++ src/ui/dialog/static-template-load-tab.cpp | 47 +++++++++++++ src/ui/dialog/static-template-load-tab.h | 33 +++++++++ src/ui/dialog/template-load-tab.cpp | 107 +++++++++++++++++++++++++++++ src/ui/dialog/template-load-tab.h | 59 ++++++++++++++++ src/verbs.cpp | 6 ++ src/verbs.h | 1 + 17 files changed, 334 insertions(+), 319 deletions(-) delete mode 100644 src/templates/new-from-template.cpp delete mode 100644 src/templates/new-from-template.h delete mode 100644 src/templates/static-template-load-tab.cpp delete mode 100644 src/templates/static-template-load-tab.h delete mode 100644 src/templates/template-load-tab.cpp delete mode 100644 src/templates/template-load-tab.h create mode 100644 src/ui/dialog/new-from-template.cpp create mode 100644 src/ui/dialog/new-from-template.h create mode 100644 src/ui/dialog/static-template-load-tab.cpp create mode 100644 src/ui/dialog/static-template-load-tab.h create mode 100644 src/ui/dialog/template-load-tab.cpp create mode 100644 src/ui/dialog/template-load-tab.h (limited to 'src') diff --git a/src/file.h b/src/file.h index fe8ad9af3..acc6c5c7c 100644 --- a/src/file.h +++ b/src/file.h @@ -45,6 +45,7 @@ Glib::ustring sp_file_default_template_uri(); */ SPDesktop* sp_file_new (const Glib::ustring &templ); SPDesktop* sp_file_new_default (void); +SPDesktop* sp_file_new_from_templatee (); /*###################### ## D E L E T E diff --git a/src/menus-skeleton.h b/src/menus-skeleton.h index 77e781763..7c412b605 100644 --- a/src/menus-skeleton.h +++ b/src/menus-skeleton.h @@ -17,6 +17,7 @@ static char const menus_skeleton[] = " \n" " \n" " \n" +" \n" " \n" " \n" " \n" diff --git a/src/templates/new-from-template.cpp b/src/templates/new-from-template.cpp deleted file mode 100644 index fc590d199..000000000 --- a/src/templates/new-from-template.cpp +++ /dev/null @@ -1,42 +0,0 @@ -#include "new-from-template.h" -#include "gtkmm/alignment.h" - -namespace Inkscape { -namespace UI { - - -NewFromTemplate::NewFromTemplate() - : _create_template_button("Create from template") -{ - set_title("New From Template"); - resize(400, 250); - - get_vbox()->pack_start(_main_widget); - _main_widget.append_page(_tab1, "Static Templates"); - _main_widget.append_page(_tab2, "Procedural Templates"); - - Gtk::Alignment *align; - align = manage(new Gtk::Alignment(Gtk::ALIGN_END, Gtk::ALIGN_CENTER, 0.0, 0.0)); - get_vbox()->pack_end(*align, Gtk::PACK_SHRINK, 5); - align->add(_create_template_button); - - _create_template_button.signal_pressed().connect( - sigc::mem_fun(*this, &NewFromTemplate::_createFromTemplate)); - - show_all(); -} - - -void NewFromTemplate::_createFromTemplate() -{ - if ( _main_widget.get_current_page() == 0 ) { - _tab1.createTemplate(); - } else { - _tab2.createTemplate(); - } - - response(0); -} - -} -} diff --git a/src/templates/new-from-template.h b/src/templates/new-from-template.h deleted file mode 100644 index ef3cbce18..000000000 --- a/src/templates/new-from-template.h +++ /dev/null @@ -1,31 +0,0 @@ -#ifndef INKSCAPE_SEEN_UI_DIALOG_NEW_FROM_TEMPLATE_H -#define INKSCAPE_SEEN_UI_DIALOG_NEW_FROM_TEMPLATE_H - -#include -#include -#include - -#include "template-load-tab.h" -#include "static-template-load-tab.h" - -namespace Inkscape { -namespace UI { - - -class NewFromTemplate : public Gtk::Dialog -{ -public: - NewFromTemplate(); - -private: - Gtk::Notebook _main_widget; - Gtk::Button _create_template_button; - StaticTemplateLoadTab _tab1; - TemplateLoadTab _tab2; - - void _createFromTemplate(); -}; - -} -} -#endif diff --git a/src/templates/static-template-load-tab.cpp b/src/templates/static-template-load-tab.cpp deleted file mode 100644 index 83ff32e52..000000000 --- a/src/templates/static-template-load-tab.cpp +++ /dev/null @@ -1,47 +0,0 @@ -#include -#include -#include -#include - -#include "static-template-load-tab.h" - -namespace Inkscape { -namespace UI { - - -StaticTemplateLoadTab::StaticTemplateLoadTab() - : _more_info_button("More info") - , _preview_image("preview.png") - , _short_description_label("Short description - I like trains. ad asda asd asdweqe gdfg") - , _template_name_label("Template_name") - , _template_author_label("by template_author") -{ - _template_info_column.pack_start(_template_name_label, Gtk::PACK_SHRINK, 4); - _template_info_column.pack_start(_template_author_label, Gtk::PACK_SHRINK, 0); - _template_info_column.pack_start(_preview_image, Gtk::PACK_SHRINK, 15); - _template_info_column.pack_start(_short_description_label, Gtk::PACK_SHRINK, 4); - - _short_description_label.set_line_wrap(true); - _short_description_label.set_size_request(200); - - Gtk::Alignment *align; - align = manage(new Gtk::Alignment(Gtk::ALIGN_END, Gtk::ALIGN_CENTER, 0.0, 0.0)); - _template_info_column.pack_start(*align, Gtk::PACK_SHRINK, 5); - align->add(_more_info_button); -} - - -void StaticTemplateLoadTab::createTemplate() -{ - std::cout << "Static template\n"; -} - - -void StaticTemplateLoadTab::_displayTemplateInfo() -{ - TemplateLoadTab::_displayTemplateInfo(); - _template_name_label.set_text(_current_template); -} - -} -} diff --git a/src/templates/static-template-load-tab.h b/src/templates/static-template-load-tab.h deleted file mode 100644 index 651f146a0..000000000 --- a/src/templates/static-template-load-tab.h +++ /dev/null @@ -1,33 +0,0 @@ -#ifndef INKSCAPE_SEEN_UI_DIALOG_STATIC_TEMPLATE_LOAD_TAB_H -#define INKSCAPE_SEEN_UI_DIALOG_STATIC_TEMPLATE_LOAD_TAB_H - -#include -#include -#include - -#include "template-load-tab.h" - -namespace Inkscape { -namespace UI { - - -class StaticTemplateLoadTab : public TemplateLoadTab -{ -public: - StaticTemplateLoadTab(); - virtual void createTemplate(); - -protected: - virtual void _displayTemplateInfo(); - - Gtk::Button _more_info_button; - Gtk::Label _short_description_label; - Gtk::Label _template_author_label; - Gtk::Label _template_name_label; - Gtk::Image _preview_image; -}; - -} -} - -#endif diff --git a/src/templates/template-load-tab.cpp b/src/templates/template-load-tab.cpp deleted file mode 100644 index a7b5e63f3..000000000 --- a/src/templates/template-load-tab.cpp +++ /dev/null @@ -1,107 +0,0 @@ -#include -#include - -#include "template-load-tab.h" - -namespace Inkscape { -namespace UI { - - -TemplateLoadTab::TemplateLoadTab() - : _keywords_combo(true) -{ - set_border_width(10); - - Gtk::Label *title; - title = manage(new Gtk::Label("Search Tags:")); - _templates_column.pack_start(*title, Gtk::PACK_SHRINK, 10); - - _templates_column.pack_start(_keywords_combo, Gtk::PACK_SHRINK, 0); - - title = manage(new Gtk::Label("Templates")); - _templates_column.pack_start(*title, Gtk::PACK_SHRINK, 10); - - title = manage(new Gtk::Label("Selected template")); - _template_info_column.pack_start(*title, Gtk::PACK_SHRINK, 10); - - _initLists(); - - add(_main_box); - _main_box.pack_start(_templates_column, Gtk::PACK_SHRINK, 20); - _main_box.pack_start(_template_info_column, Gtk::PACK_EXPAND_WIDGET, 10); - - _templates_column.pack_start(_templates_view, Gtk::PACK_SHRINK, 5); - - Glib::RefPtr templateSelectionRef = - _templates_view.get_selection(); - - templateSelectionRef->signal_changed().connect( - sigc::mem_fun(*this, &TemplateLoadTab::_displayTemplateInfo)); - - _keywords_combo.signal_changed().connect( - sigc::mem_fun(*this, &TemplateLoadTab::_keywordSelected)); - this->show_all(); -} - - -TemplateLoadTab::~TemplateLoadTab() -{ -} - - -void TemplateLoadTab::createTemplate() -{ - std::cout << "Default Template Tab" << std::endl; -} - - -void TemplateLoadTab::_displayTemplateInfo() -{ - Glib::RefPtr templateSelectionRef = _templates_view.get_selection(); - if (templateSelectionRef->get_selected()) { - _current_template = (*templateSelectionRef->get_selected())[_templates_columns.textValue]; - } -} - - -void TemplateLoadTab::_initKeywordsList() -{ - _keywords_combo.append_text("All"); - - for (int i = 0 ; i < 10 ; ++i) { - _keywords_combo.append_text( "Keyword" + Glib::ustring::format(i)); - } -} - - -void TemplateLoadTab::_initLists() -{ - _templates_ref = Gtk::ListStore::create(_templates_columns); - _templates_view.set_model(_templates_ref); - _templates_view.append_column("", _templates_columns.textValue); - _templates_view.set_headers_visible(false); - - _initKeywordsList(); - _refreshTemplatesList(); -} - - -void TemplateLoadTab::_keywordSelected() -{ - _current_keyword = _keywords_combo.get_active_text(); - _refreshTemplatesList(); -} - - -void TemplateLoadTab::_refreshTemplatesList() -{ - _templates_ref->clear(); - for (int i = 0 ; i < 7 ; ++i) { - Gtk::TreeModel::iterator iter = _templates_ref->append(); - Gtk::TreeModel::Row row = *iter; - row[_templates_columns.textValue] = "Template" + Glib::ustring::format(i); - } -} - -} -} diff --git a/src/templates/template-load-tab.h b/src/templates/template-load-tab.h deleted file mode 100644 index a9fa7c313..000000000 --- a/src/templates/template-load-tab.h +++ /dev/null @@ -1,59 +0,0 @@ -#ifndef INKSCAPE_SEEN_UI_DIALOG_TEMPLATE_LOAD_TAB_H -#define INKSCAPE_SEEN_UI_DIALOG_TEMPLATE_LOAD_TAB_H - -#include -#include -#include -#include -#include - -namespace Inkscape { -namespace UI { - - -class TemplateLoadTab : public Gtk::Frame -{ - -public: - TemplateLoadTab(); - virtual ~TemplateLoadTab(); - virtual void createTemplate(); - -protected: - class StringModelColumns : public Gtk::TreeModelColumnRecord - { - public: - StringModelColumns() - { - add(textValue); - } - - Gtk::TreeModelColumn textValue; - }; - - Glib::ustring _current_keyword; - Glib::ustring _current_template; - - virtual void _displayTemplateInfo(); - virtual void _initKeywordsList(); - virtual void _refreshTemplatesList(); - - void _initLists(); - void _keywordSelected(); - - Gtk::HBox _main_box; - Gtk::VBox _templates_column; - Gtk::VBox _template_info_column; - - Gtk::ComboBoxText _keywords_combo; - - Gtk::TreeView _templates_view; - Glib::RefPtr _templates_ref; - StringModelColumns _templates_columns; - -}; - -} -} - -#endif diff --git a/src/ui/dialog/Makefile_insert b/src/ui/dialog/Makefile_insert index 580b47522..4a34cc71c 100644 --- a/src/ui/dialog/Makefile_insert +++ b/src/ui/dialog/Makefile_insert @@ -70,6 +70,8 @@ ink_common_sources += \ ui/dialog/memory.h \ ui/dialog/messages.cpp \ ui/dialog/messages.h \ + ui/dialog/new-from-template.cpp \ + ui/dialog/new-from-template.h \ ui/dialog/ocaldialogs.cpp \ ui/dialog/ocaldialogs.h \ ui/dialog/object-attributes.cpp \ @@ -85,12 +87,16 @@ ink_common_sources += \ ui/dialog/scriptdialog.h \ ui/dialog/spellcheck.cpp \ ui/dialog/spellcheck.h \ + ui/dialog/static-template-load-tab.cpp \ + ui/dialog/static-template-load-tab.h \ ui/dialog/svg-fonts-dialog.cpp \ ui/dialog/svg-fonts-dialog.h \ ui/dialog/swatches.cpp \ ui/dialog/swatches.h \ ui/dialog/symbols.cpp \ ui/dialog/symbols.h \ + ui/dialog/template-load-tab.cpp \ + ui/dialog/template-load-tab.h \ ui/dialog/text-edit.cpp \ ui/dialog/text-edit.h \ ui/dialog/tile.cpp \ diff --git a/src/ui/dialog/new-from-template.cpp b/src/ui/dialog/new-from-template.cpp new file mode 100644 index 000000000..fc590d199 --- /dev/null +++ b/src/ui/dialog/new-from-template.cpp @@ -0,0 +1,42 @@ +#include "new-from-template.h" +#include "gtkmm/alignment.h" + +namespace Inkscape { +namespace UI { + + +NewFromTemplate::NewFromTemplate() + : _create_template_button("Create from template") +{ + set_title("New From Template"); + resize(400, 250); + + get_vbox()->pack_start(_main_widget); + _main_widget.append_page(_tab1, "Static Templates"); + _main_widget.append_page(_tab2, "Procedural Templates"); + + Gtk::Alignment *align; + align = manage(new Gtk::Alignment(Gtk::ALIGN_END, Gtk::ALIGN_CENTER, 0.0, 0.0)); + get_vbox()->pack_end(*align, Gtk::PACK_SHRINK, 5); + align->add(_create_template_button); + + _create_template_button.signal_pressed().connect( + sigc::mem_fun(*this, &NewFromTemplate::_createFromTemplate)); + + show_all(); +} + + +void NewFromTemplate::_createFromTemplate() +{ + if ( _main_widget.get_current_page() == 0 ) { + _tab1.createTemplate(); + } else { + _tab2.createTemplate(); + } + + response(0); +} + +} +} diff --git a/src/ui/dialog/new-from-template.h b/src/ui/dialog/new-from-template.h new file mode 100644 index 000000000..ef3cbce18 --- /dev/null +++ b/src/ui/dialog/new-from-template.h @@ -0,0 +1,31 @@ +#ifndef INKSCAPE_SEEN_UI_DIALOG_NEW_FROM_TEMPLATE_H +#define INKSCAPE_SEEN_UI_DIALOG_NEW_FROM_TEMPLATE_H + +#include +#include +#include + +#include "template-load-tab.h" +#include "static-template-load-tab.h" + +namespace Inkscape { +namespace UI { + + +class NewFromTemplate : public Gtk::Dialog +{ +public: + NewFromTemplate(); + +private: + Gtk::Notebook _main_widget; + Gtk::Button _create_template_button; + StaticTemplateLoadTab _tab1; + TemplateLoadTab _tab2; + + void _createFromTemplate(); +}; + +} +} +#endif diff --git a/src/ui/dialog/static-template-load-tab.cpp b/src/ui/dialog/static-template-load-tab.cpp new file mode 100644 index 000000000..83ff32e52 --- /dev/null +++ b/src/ui/dialog/static-template-load-tab.cpp @@ -0,0 +1,47 @@ +#include +#include +#include +#include + +#include "static-template-load-tab.h" + +namespace Inkscape { +namespace UI { + + +StaticTemplateLoadTab::StaticTemplateLoadTab() + : _more_info_button("More info") + , _preview_image("preview.png") + , _short_description_label("Short description - I like trains. ad asda asd asdweqe gdfg") + , _template_name_label("Template_name") + , _template_author_label("by template_author") +{ + _template_info_column.pack_start(_template_name_label, Gtk::PACK_SHRINK, 4); + _template_info_column.pack_start(_template_author_label, Gtk::PACK_SHRINK, 0); + _template_info_column.pack_start(_preview_image, Gtk::PACK_SHRINK, 15); + _template_info_column.pack_start(_short_description_label, Gtk::PACK_SHRINK, 4); + + _short_description_label.set_line_wrap(true); + _short_description_label.set_size_request(200); + + Gtk::Alignment *align; + align = manage(new Gtk::Alignment(Gtk::ALIGN_END, Gtk::ALIGN_CENTER, 0.0, 0.0)); + _template_info_column.pack_start(*align, Gtk::PACK_SHRINK, 5); + align->add(_more_info_button); +} + + +void StaticTemplateLoadTab::createTemplate() +{ + std::cout << "Static template\n"; +} + + +void StaticTemplateLoadTab::_displayTemplateInfo() +{ + TemplateLoadTab::_displayTemplateInfo(); + _template_name_label.set_text(_current_template); +} + +} +} diff --git a/src/ui/dialog/static-template-load-tab.h b/src/ui/dialog/static-template-load-tab.h new file mode 100644 index 000000000..651f146a0 --- /dev/null +++ b/src/ui/dialog/static-template-load-tab.h @@ -0,0 +1,33 @@ +#ifndef INKSCAPE_SEEN_UI_DIALOG_STATIC_TEMPLATE_LOAD_TAB_H +#define INKSCAPE_SEEN_UI_DIALOG_STATIC_TEMPLATE_LOAD_TAB_H + +#include +#include +#include + +#include "template-load-tab.h" + +namespace Inkscape { +namespace UI { + + +class StaticTemplateLoadTab : public TemplateLoadTab +{ +public: + StaticTemplateLoadTab(); + virtual void createTemplate(); + +protected: + virtual void _displayTemplateInfo(); + + Gtk::Button _more_info_button; + Gtk::Label _short_description_label; + Gtk::Label _template_author_label; + Gtk::Label _template_name_label; + Gtk::Image _preview_image; +}; + +} +} + +#endif diff --git a/src/ui/dialog/template-load-tab.cpp b/src/ui/dialog/template-load-tab.cpp new file mode 100644 index 000000000..a7b5e63f3 --- /dev/null +++ b/src/ui/dialog/template-load-tab.cpp @@ -0,0 +1,107 @@ +#include +#include + +#include "template-load-tab.h" + +namespace Inkscape { +namespace UI { + + +TemplateLoadTab::TemplateLoadTab() + : _keywords_combo(true) +{ + set_border_width(10); + + Gtk::Label *title; + title = manage(new Gtk::Label("Search Tags:")); + _templates_column.pack_start(*title, Gtk::PACK_SHRINK, 10); + + _templates_column.pack_start(_keywords_combo, Gtk::PACK_SHRINK, 0); + + title = manage(new Gtk::Label("Templates")); + _templates_column.pack_start(*title, Gtk::PACK_SHRINK, 10); + + title = manage(new Gtk::Label("Selected template")); + _template_info_column.pack_start(*title, Gtk::PACK_SHRINK, 10); + + _initLists(); + + add(_main_box); + _main_box.pack_start(_templates_column, Gtk::PACK_SHRINK, 20); + _main_box.pack_start(_template_info_column, Gtk::PACK_EXPAND_WIDGET, 10); + + _templates_column.pack_start(_templates_view, Gtk::PACK_SHRINK, 5); + + Glib::RefPtr templateSelectionRef = + _templates_view.get_selection(); + + templateSelectionRef->signal_changed().connect( + sigc::mem_fun(*this, &TemplateLoadTab::_displayTemplateInfo)); + + _keywords_combo.signal_changed().connect( + sigc::mem_fun(*this, &TemplateLoadTab::_keywordSelected)); + this->show_all(); +} + + +TemplateLoadTab::~TemplateLoadTab() +{ +} + + +void TemplateLoadTab::createTemplate() +{ + std::cout << "Default Template Tab" << std::endl; +} + + +void TemplateLoadTab::_displayTemplateInfo() +{ + Glib::RefPtr templateSelectionRef = _templates_view.get_selection(); + if (templateSelectionRef->get_selected()) { + _current_template = (*templateSelectionRef->get_selected())[_templates_columns.textValue]; + } +} + + +void TemplateLoadTab::_initKeywordsList() +{ + _keywords_combo.append_text("All"); + + for (int i = 0 ; i < 10 ; ++i) { + _keywords_combo.append_text( "Keyword" + Glib::ustring::format(i)); + } +} + + +void TemplateLoadTab::_initLists() +{ + _templates_ref = Gtk::ListStore::create(_templates_columns); + _templates_view.set_model(_templates_ref); + _templates_view.append_column("", _templates_columns.textValue); + _templates_view.set_headers_visible(false); + + _initKeywordsList(); + _refreshTemplatesList(); +} + + +void TemplateLoadTab::_keywordSelected() +{ + _current_keyword = _keywords_combo.get_active_text(); + _refreshTemplatesList(); +} + + +void TemplateLoadTab::_refreshTemplatesList() +{ + _templates_ref->clear(); + for (int i = 0 ; i < 7 ; ++i) { + Gtk::TreeModel::iterator iter = _templates_ref->append(); + Gtk::TreeModel::Row row = *iter; + row[_templates_columns.textValue] = "Template" + Glib::ustring::format(i); + } +} + +} +} diff --git a/src/ui/dialog/template-load-tab.h b/src/ui/dialog/template-load-tab.h new file mode 100644 index 000000000..a9fa7c313 --- /dev/null +++ b/src/ui/dialog/template-load-tab.h @@ -0,0 +1,59 @@ +#ifndef INKSCAPE_SEEN_UI_DIALOG_TEMPLATE_LOAD_TAB_H +#define INKSCAPE_SEEN_UI_DIALOG_TEMPLATE_LOAD_TAB_H + +#include +#include +#include +#include +#include + +namespace Inkscape { +namespace UI { + + +class TemplateLoadTab : public Gtk::Frame +{ + +public: + TemplateLoadTab(); + virtual ~TemplateLoadTab(); + virtual void createTemplate(); + +protected: + class StringModelColumns : public Gtk::TreeModelColumnRecord + { + public: + StringModelColumns() + { + add(textValue); + } + + Gtk::TreeModelColumn textValue; + }; + + Glib::ustring _current_keyword; + Glib::ustring _current_template; + + virtual void _displayTemplateInfo(); + virtual void _initKeywordsList(); + virtual void _refreshTemplatesList(); + + void _initLists(); + void _keywordSelected(); + + Gtk::HBox _main_box; + Gtk::VBox _templates_column; + Gtk::VBox _template_info_column; + + Gtk::ComboBoxText _keywords_combo; + + Gtk::TreeView _templates_view; + Glib::RefPtr _templates_ref; + StringModelColumns _templates_columns; + +}; + +} +} + +#endif diff --git a/src/verbs.cpp b/src/verbs.cpp index 6f83b3dfb..a3d8b07a2 100644 --- a/src/verbs.cpp +++ b/src/verbs.cpp @@ -79,6 +79,7 @@ #include "ui/dialog/inkscape-preferences.h" #include "ui/dialog/layer-properties.h" #include "ui/dialog/layers.h" +#include "ui/dialog/new-from-template.h" #include "ui/dialog/object-properties.h" #include "ui/dialog/swatches.h" #include "ui/dialog/symbols.h" @@ -860,6 +861,9 @@ void FileVerb::perform(SPAction *action, void *data) case SP_VERB_FILE_QUIT: sp_file_exit(); break; + case SP_VERB_FILE_TEMPLATES: + sp_file_new_from_templatee(); + break; default: break; } @@ -2323,6 +2327,8 @@ Verb *Verb::_base_verbs[] = { new FileVerb(SP_VERB_FILE_CLOSE_VIEW, "FileClose", N_("_Close"), N_("Close this document window"), GTK_STOCK_CLOSE), new FileVerb(SP_VERB_FILE_QUIT, "FileQuit", N_("_Quit"), N_("Quit Inkscape"), GTK_STOCK_QUIT), + new FileVerb(SP_VERB_FILE_TEMPLATES, "FileTemplates", N_("_Templates..."), + N_("Create new project from template"), INKSCAPE_ICON("dialog-templates")), // Edit new EditVerb(SP_VERB_EDIT_UNDO, "EditUndo", N_("_Undo"), N_("Undo last action"), diff --git a/src/verbs.h b/src/verbs.h index dab524d7a..3c1625c84 100644 --- a/src/verbs.h +++ b/src/verbs.h @@ -56,6 +56,7 @@ enum { SP_VERB_FILE_PREV_DESKTOP, SP_VERB_FILE_CLOSE_VIEW, SP_VERB_FILE_QUIT, + SP_VERB_FILE_TEMPLATES, /* Edit */ SP_VERB_EDIT_UNDO, SP_VERB_EDIT_REDO, -- cgit v1.2.3