diff options
| author | Jon A. Cruz <jon@joncruz.org> | 2010-04-01 09:36:46 +0000 |
|---|---|---|
| committer | Jon A. Cruz <jon@joncruz.org> | 2010-04-01 09:36:46 +0000 |
| commit | ca353feacd19d98d8fee95bcd1bd018431034a1e (patch) | |
| tree | 83f5d0805185028f623ca001a009a06982a9e90b /src/ui | |
| parent | Patch by Daniel_J for 522327 (diff) | |
| download | inkscape-ca353feacd19d98d8fee95bcd1bd018431034a1e.tar.gz inkscape-ca353feacd19d98d8fee95bcd1bd018431034a1e.zip | |
Initial cut of glyph selector dialog is in. Fixes bug #343186.
Fixed bugs:
- https://launchpad.net/bugs/343186
(bzr r9268)
Diffstat (limited to 'src/ui')
| -rw-r--r-- | src/ui/dialog/Makefile_insert | 2 | ||||
| -rw-r--r-- | src/ui/dialog/dialog-manager.cpp | 7 | ||||
| -rw-r--r-- | src/ui/widget/panel.cpp | 12 |
3 files changed, 13 insertions, 8 deletions
diff --git a/src/ui/dialog/Makefile_insert b/src/ui/dialog/Makefile_insert index 033bec875..7546bc195 100644 --- a/src/ui/dialog/Makefile_insert +++ b/src/ui/dialog/Makefile_insert @@ -50,6 +50,8 @@ ink_common_sources += \ ui/dialog/find.h \ ui/dialog/floating-behavior.cpp \ ui/dialog/floating-behavior.h \ + ui/dialog/glyphs.cpp \ + ui/dialog/glyphs.h \ ui/dialog/guides.cpp \ ui/dialog/guides.h \ ui/dialog/icon-preview.cpp \ diff --git a/src/ui/dialog/dialog-manager.cpp b/src/ui/dialog/dialog-manager.cpp index 30cbed649..6d3bc817e 100644 --- a/src/ui/dialog/dialog-manager.cpp +++ b/src/ui/dialog/dialog-manager.cpp @@ -25,6 +25,7 @@ #include "ui/dialog/fill-and-stroke.h" #include "ui/dialog/filter-effects-dialog.h" #include "ui/dialog/find.h" +#include "ui/dialog/glyphs.h" #include "ui/dialog/inkscape-preferences.h" #include "ui/dialog/input.h" #include "ui/dialog/livepatheffect-editor.h" @@ -96,6 +97,7 @@ DialogManager::DialogManager() { registerFactory("FillAndStroke", &create<FillAndStroke, FloatingBehavior>); registerFactory("FilterEffectsDialog", &create<FilterEffectsDialog, FloatingBehavior>); registerFactory("Find", &create<Find, FloatingBehavior>); + registerFactory("Glyphs", &create<GlyphsPanel, FloatingBehavior>); registerFactory("IconPreviewPanel", &create<IconPreviewPanel, FloatingBehavior>); registerFactory("InkscapePreferences", &create<InkscapePreferences, FloatingBehavior>); registerFactory("LayersPanel", &create<LayersPanel, FloatingBehavior>); @@ -123,6 +125,7 @@ DialogManager::DialogManager() { registerFactory("FillAndStroke", &create<FillAndStroke, DockBehavior>); registerFactory("FilterEffectsDialog", &create<FilterEffectsDialog, DockBehavior>); registerFactory("Find", &create<Find, DockBehavior>); + registerFactory("Glyphs", &create<GlyphsPanel, DockBehavior>); registerFactory("IconPreviewPanel", &create<IconPreviewPanel, DockBehavior>); registerFactory("InkscapePreferences", &create<InkscapePreferences, DockBehavior>); registerFactory("LayersPanel", &create<LayersPanel, DockBehavior>); @@ -159,11 +162,11 @@ DialogManager &DialogManager::getInstance() /* Use singleton behavior for floating dialogs */ if (dialogs_type == FLOATING) { static DialogManager *instance = 0; - + if (!instance) instance = new DialogManager(); return *instance; - } + } return *new DialogManager(); } diff --git a/src/ui/widget/panel.cpp b/src/ui/widget/panel.cpp index 93a950d1a..4b806afb5 100644 --- a/src/ui/widget/panel.cpp +++ b/src/ui/widget/panel.cpp @@ -133,9 +133,9 @@ void Panel::_init() { //TRANSLATORS: only translate "string" in "context|string". // For more details, see http://developer.gnome.org/doc/API/2.0/glib/glib-I18N.html#Q-:CAPS - Glib::ustring heightItemLabel(Q_("swatches|Size")); + Glib::ustring heightItemLabel(Q_("swatches|Size")); - //TRANSLATORS: Indicates size of colour swatches + //TRANSLATORS: Indicates size of colour swatches const gchar *heightLabels[] = { N_("tiny"), N_("small"), @@ -157,7 +157,7 @@ void Panel::_init() Gtk::RadioMenuItem* _item = manage(new Gtk::RadioMenuItem(heightGroup, _label)); sizeMenu->append(*_item); if (i == panel_size) { - _item->set_active(true); + _item->set_active(true); } _item->signal_activate().connect(sigc::bind<int, int>(sigc::mem_fun(*this, &Panel::_bounceCall), PANEL_SETTING_SIZE, i)); } @@ -198,11 +198,11 @@ void Panel::_init() } } for ( guint i = 0; i < G_N_ELEMENTS(widthLabels); ++i ) { - Glib::ustring _label(Q_(widthLabels[i])); + Glib::ustring _label(Q_(widthLabels[i])); Gtk::RadioMenuItem *_item = manage(new Gtk::RadioMenuItem(widthGroup, _label)); type_menu->append(*_item); if ( i <= hot_index ) { - _item->set_active(true); + _item->set_active(true); } _item->signal_activate().connect(sigc::bind<int, int>(sigc::mem_fun(*this, &Panel::_bounceCall), PANEL_SETTING_SHAPE, values[i])); } @@ -212,7 +212,7 @@ void Panel::_init() //TRANSLATORS: only translate "string" in "context|string". // For more details, see http://developer.gnome.org/doc/API/2.0/glib/glib-I18N.html#Q-:CAPS // "Wrap" indicates how colour swatches are displayed - Glib::ustring wrap_label(Q_("swatches|Wrap")); + Glib::ustring wrap_label(Q_("swatches|Wrap")); Gtk::CheckMenuItem *check = manage(new Gtk::CheckMenuItem(wrap_label)); check->set_active(panel_wrap); _menu->append(*check); |
