I’m in a very curious situation. I have a Gtk.Label
created as shown below with markup support enabled:
<child>
<object class="GtkLabel" id="_pr_label">
<property name="label" translatable="yes"><b>Functions parameters:</b>.
<b>Ex.:</b> >15: greater than number(inclusive).
<b>Ex.:</b> 6,8,10; relation of arbiterary numbers.
<b>Ex.:</b> 4; a singles number.
<b>Ex.:</b> <10: lower than number (inclusive).
<b>Ex.:</b> 80..90; Interval between numbers (inclusive).
</property>
<property name="wrap">true</property>
<property name="justify">3</property>
<property name="xalign">0</property>
<property name="use-markup">true</property>
<property name="margin-top">15</property>
</object>
</child>
The XML escapes the “<” character using “<”, but the pango markup generates an error because I don’t know how to escape the character when the text is created directly in the XML (If it is created in the code there are ways to do it).
from markup due to error parsing markup: ...: “10” is not a valid character following a “<” character; it may not begin an element name
Is there a way to escape the “<” character for the pango markup without using a function for this? Directly via some element in the text?
The funny thing is that the “>” character doesn’t cause any problems.