diff options
| author | Martin Owens <doctormo@gmail.com> | 2013-09-20 04:45:16 +0000 |
|---|---|---|
| committer | Martin Owens <doctormo@gmail.com> | 2013-09-20 04:45:16 +0000 |
| commit | eb3598e7e27619c759ef33bb9ec4ffb8898523de (patch) | |
| tree | 3793d7310b4cdea6ffaea3fe7ee837b3ede065cf /src/sp-star.cpp | |
| parent | Fix make check after merge of cppify branch (diff) | |
| download | inkscape-eb3598e7e27619c759ef33bb9ec4ffb8898523de.tar.gz inkscape-eb3598e7e27619c759ef33bb9ec4ffb8898523de.zip | |
Refactor status-bar text for multiple items, was very broken
Fixed bugs:
- https://launchpad.net/bugs/1199192
(bzr r12550)
Diffstat (limited to 'src/sp-star.cpp')
| -rw-r--r-- | src/sp-star.cpp | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/src/sp-star.cpp b/src/sp-star.cpp index 4a3a8cbe3..e5c5c7c25 100644 --- a/src/sp-star.cpp +++ b/src/sp-star.cpp @@ -251,19 +251,18 @@ void SPStar::update_patheffect(bool write) { this->requestDisplayUpdate(SP_OBJECT_MODIFIED_FLAG); } +const char* SPStar::display_name() { + if (this->flatsided == false) + return _("Star"); + return _("Polygon"); +} + gchar* SPStar::description() { // while there will never be less than 3 vertices, we still need to // make calls to ngettext because the pluralization may be different // for various numbers >=3. The singular form is used as the index. - if (this->flatsided == false) { - return g_strdup_printf (ngettext("<b>Star</b> with %d vertex", - "<b>Star</b> with %d vertices", - this->sides), this->sides); - } else { - return g_strdup_printf (ngettext("<b>Polygon</b> with %d vertex", - "<b>Polygon</b> with %d vertices", - this->sides), this->sides); - } + return g_strdup_printf (ngettext(_("with %d vertex"), _("with %d vertices"), + this->sides), this->sides); } /** |
