diff options
| author | Tavmjong Bah <tavmjong@free.fr> | 2016-08-29 12:30:41 +0000 |
|---|---|---|
| committer | tavmjong-free <tavmjong@free.fr> | 2016-08-29 12:30:41 +0000 |
| commit | 4f0e9e1e2b91c661060f1dcd45deb3dc53c72093 (patch) | |
| tree | aa94e1229522d0a4342bd58f740d9d7e008d8ab2 /src/ui | |
| parent | Code design. Replacing tabs with spaces, and fixng parentheses warning. (diff) | |
| download | inkscape-4f0e9e1e2b91c661060f1dcd45deb3dc53c72093.tar.gz inkscape-4f0e9e1e2b91c661060f1dcd45deb3dc53c72093.zip | |
Don't write out sodipodi:line-spacing. Don't read if 'line-height' already set.
Partial fix for #1590141.
(bzr r15085)
Diffstat (limited to 'src/ui')
| -rw-r--r-- | src/ui/dialog/text-edit.cpp | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/src/ui/dialog/text-edit.cpp b/src/ui/dialog/text-edit.cpp index 50c6c1553..9efbcf6a8 100644 --- a/src/ui/dialog/text-edit.cpp +++ b/src/ui/dialog/text-edit.cpp @@ -505,9 +505,7 @@ SPCSSAttr *TextEdit::fillTextStyle () sp_repr_css_set_property (css, "writing-mode", "tb"); } - // Note that SVG 1.1 does not support line-height; we set it for consistency, but also set - // sodipodi:linespacing for backwards compatibility; in 1.2 we use line-height for flowtext - + // Note that SVG 1.1 does not support line-height but we use it. const gchar *sstr = gtk_combo_box_text_get_active_text ((GtkComboBoxText *) spacing_combo); sp_repr_css_set_property (css, "line-height", sstr); @@ -542,18 +540,11 @@ void TextEdit::onApply() SPCSSAttr *css = fillTextStyle (); sp_desktop_set_style(desktop, css, true); - for(auto i=item_list.begin();i!=item_list.end();++i){ + for(auto i=item_list.begin();i!=item_list.end();++i){ // apply style to the reprs of all text objects in the selection - if (SP_IS_TEXT (*i)) { - - // backwards compatibility: - (*i)->getRepr()->setAttribute("sodipodi:linespacing", sp_repr_css_property (css, "line-height", NULL)); - + if (SP_IS_TEXT (*i) || (SP_IS_FLOWTEXT (*i)) ) { ++items; } - else if (SP_IS_FLOWTEXT (*i)) - // no need to set sodipodi:linespacing, because Inkscape never supported it on flowtext - ++items; } if (items == 0) { |
