pencil
pencil copied to clipboard
Cannot use & in window frame title (sketchy GUI)
From cortex.sk on September 03, 2013 03:45:41
Package version 2.0.3 from official site. Distribution: Kubuntu 13.04
If I want to use "&" in window frame title (from sketchy gui) for example "Calendars & Contacts", the title will remain unchanged. On double clicking i see the text.
demonstration: http://youtu.be/WJTExEzhjIM
Original issue: http://code.google.com/p/evoluspencil/issues/detail?id=582
This solves the problem:
diff --git a/app/content/pencil/stencil/SketchyGUI/Definition.xml b/app/content/pencil/stencil/SketchyGUI/Definition.xml
index 873fa89..b2749bc 100644
--- a/app/content/pencil/stencil/SketchyGUI/Definition.xml
+++ b/app/content/pencil/stencil/SketchyGUI/Definition.xml
@@ -1551,9 +1551,7 @@ MenuItem]]></Property>
<path id="body" style="fill:white;stroke:black"/>
<path id="menu" style="fill:white;stroke:black"/>
<path id="button" style="fill:white;stroke:black"/>
- <foreignObject x="0" y="0" width="200" height="100" id="text">
- <div xmlns="http://www.w3.org/1999/xhtml"></div>
- </foreignObject>
+ <text id="text"/>
</p:Content>
</Shape>
... but is this a good solution? I think it is an improvement NOT to use the ForeignObject construction in the SVG result, since these ForeignObject things are only supported by Firefox, and not by any other SVG tool.
To be tested: does this change break backward compatibility when saving? Any other problems?
I tested the compatibility: no problem. Rests the question: Is this a good solution?
I've noticed this in multiple elements.
I will checkout ForeignObject vs text.
I think the other solution is to escape the text, writing &
produces an ampersand.