summaryrefslogtreecommitdiff
path: root/docs/pango_markup.md
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2021-03-24 17:08:14 -0400
committerMatthias Clasen <mclasen@redhat.com>2021-03-24 17:08:14 -0400
commita47cfee23756f09266d5f3a0ce3ea50c2f540005 (patch)
treeab38c7482c4c9ff551af2b71924ab14343df418e /docs/pango_markup.md
parentfdc432bc8d9222538bbcc3e973ce1a3a6a86fb5b (diff)
downloadpango-a47cfee23756f09266d5f3a0ce3ea50c2f540005.tar.gz
Add some markup examplesmarkup-examples
A little color doesn't hurt.
Diffstat (limited to 'docs/pango_markup.md')
-rw-r--r--docs/pango_markup.md11
1 files changed, 11 insertions, 0 deletions
diff --git a/docs/pango_markup.md b/docs/pango_markup.md
index dc6047d3..8541a71f 100644
--- a/docs/pango_markup.md
+++ b/docs/pango_markup.md
@@ -42,6 +42,17 @@ A simple example of a marked-up string might be:
<span foreground="blue" size="x-large">Blue text</span> is <i>cool</i>!"
```
+![Markup example](blue-text.png)
+
+A more elaborate example of using markup to color combining marks in
+Arabic text:
+
+```
+<span foreground="purple">ا</span><span foreground="red">َ</span>ل<span foreground="blue">ْ</span>ع<span foreground="red">َ</span>ر<span foreground="red">َ</span>ب<span foreground="red">ِ</span>ي<span foreground="green">ّ</span><span foreground="red">َ</span>ة<span foreground="blue">ُ</span>
+```
+
+![Markup example](arabic-markup.png)
+
Pango uses GMarkup to parse this language, which means that XML features
such as numeric character entities such as `&#169;` for © can be used too.