summaryrefslogtreecommitdiffstats
path: root/src/text-editing.cpp
diff options
context:
space:
mode:
authorJabier Arraiza Cenoz <jabier.arraiza@marker.es>2016-03-14 16:37:50 +0000
committerJabiertxof <jtx@jtx.marker.es>2016-03-14 16:37:50 +0000
commitb8d22beef5345210ad27cdc2685083aeae6f8f3b (patch)
treed69b8bfd19d3627a8425a1b265c2abf229b05354 /src/text-editing.cpp
parentfixes for update to trunk (diff)
parent"Relative to" option for node alignment. (diff)
downloadinkscape-b8d22beef5345210ad27cdc2685083aeae6f8f3b.tar.gz
inkscape-b8d22beef5345210ad27cdc2685083aeae6f8f3b.zip
update to trunk
(bzr r13708.1.39)
Diffstat (limited to 'src/text-editing.cpp')
-rw-r--r--src/text-editing.cpp14
1 files changed, 11 insertions, 3 deletions
diff --git a/src/text-editing.cpp b/src/text-editing.cpp
index 050e223eb..057523b1e 100644
--- a/src/text-editing.cpp
+++ b/src/text-editing.cpp
@@ -68,7 +68,7 @@ void te_update_layout_now_recursive(SPItem *item)
{
if (SP_IS_GROUP(item)) {
std::vector<SPItem*> item_list = sp_item_group_item_list(SP_GROUP(item));
- for(std::vector<SPItem*>::const_iterator i=item_list.begin();i!=item_list.end();i++){
+ for(std::vector<SPItem*>::const_iterator i=item_list.begin();i!=item_list.end();++i){
SPItem* list_item = *i;
te_update_layout_now_recursive(list_item);
}
@@ -1805,6 +1805,14 @@ static bool tidy_operator_redundant_semi_nesting(SPObject **item, bool /*has_tex
return false;
}
+
+/* tidy_operator_styled_whitespace commented out: not only did it have bugs,
+ * but it did *not* preserve the rendering: spaces in different font sizes,
+ * for instance, have different width, so moving them out of tspans changes
+ * the document. cf https://bugs.launchpad.net/inkscape/+bug/1477723
+*/
+
+#if 0
/** helper for tidy_operator_styled_whitespace(), finds the last string object
in a paragraph which is not \a not_obj. */
static SPString* find_last_string_child_not_equal_to(SPObject *root, SPObject *not_obj)
@@ -1883,6 +1891,7 @@ static bool tidy_operator_styled_whitespace(SPObject **item, bool has_text_decor
delete_obj->deleteObject();
return true;
}
+#endif
/* possible tidy operators that are not yet implemented, either because
they are difficult, occur infrequently, or because I'm not sure that the
@@ -1917,8 +1926,7 @@ static bool tidy_xml_tree_recursively(SPObject *root, bool has_text_decoration)
tidy_operator_repeated_spans,
tidy_operator_excessive_nesting,
tidy_operator_redundant_double_nesting,
- tidy_operator_redundant_semi_nesting,
- tidy_operator_styled_whitespace
+ tidy_operator_redundant_semi_nesting
};
bool changes = false;