[pango/gi-docs: 22/50] Tweaks
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pango/gi-docs: 22/50] Tweaks
- Date: Tue, 16 Feb 2021 04:14:32 +0000 (UTC)
commit f97594bdccd3ed5c3e6b6934d4d56d8f402e6132
Author: Matthias Clasen <mclasen redhat com>
Date: Thu Feb 4 21:38:09 2021 -0500
Tweaks
Fix some cases of missing ``, and remove extraneous headings.
docs/pango.toml | 2 +-
docs/pango_markup.md | 18 +++++++++---------
docs/pango_rendering.md | 19 ++++++++-----------
3 files changed, 18 insertions(+), 21 deletions(-)
---
diff --git a/docs/pango.toml b/docs/pango.toml
index 0e3decf6..f34d7cfa 100644
--- a/docs/pango.toml
+++ b/docs/pango.toml
@@ -55,7 +55,7 @@ base_url = "https://gitlab.gnome.org/GNOME/pango/-/blob/master/"
[extra]
content_files = [
- [ "pango_rendering.md", "Pango Rendering" ],
+ [ "pango_rendering.md", "The Rendering Pipeline" ],
[ "pango_markup.md", "Pango Markup" ],
]
content_images = [
diff --git a/docs/pango_markup.md b/docs/pango_markup.md
index 022a1923..0b571228 100644
--- a/docs/pango_markup.md
+++ b/docs/pango_markup.md
@@ -1,5 +1,3 @@
-# Pango Text Attribute Markup Language
-
Frequently, you want to display some text to the user with attributes
applied to part of the text (for example, you might want bold or
italicized words). With the base Pango interfaces, you could create a
@@ -17,15 +15,17 @@ pango_markup_parser_new().
A simple example of a marked-up string might be:
- <span foreground="blue" size="x-large">Blue text</span> is <i>cool</i>!"
+```
+<span foreground="blue" size="x-large">Blue text</span> is <i>cool</i>!"
+```
Pango uses GMarkup to parse this language, which means that XML features
such as numeric character entities such as `©` for © can be used too.
-The root tag of a marked-up document is <markup>, but pango_parse_markup()
+The root tag of a marked-up document is `<markup>`, but pango_parse_markup()
allows you to omit this tag, so you will most likely never need to use it.
-The most general markup tag is <span>, then there are some convenience
-tags. <span> has the following attributes:
+The most general markup tag is `<span>`, then there are some convenience
+tags. `<span>` has the following attributes:
* **font**, **font_desc**: A font description string, such as "Sans Italic 12".
See pango_font_description_from_string() for a description of the format of
@@ -53,7 +53,7 @@ tags. <span> has the following attributes:
'condensed', 'semicondensed', 'normal', 'semiexpanded', 'expanded',
'extraexpanded', 'ultraexpanded'.
-* **font_features**: A comma separated list of OpenType font feature settings, in
+* **font_features**: A comma-separated list of OpenType font feature settings, in
the same syntax as accepted by CSS. E.g: `font_features='dlig=1, -kern, afrc on'`.
* **foreground**, **fgcolor**, **color**: An RGB color specification such as
@@ -102,11 +102,11 @@ tags. <span> has the following attributes:
The following convenience tags are provided:
* **b**: Bold
-* **big**: Makes font relatively larger, equivalent to <span size="larger">
+* **big**: Makes font relatively larger, equivalent to `<span size="larger">`
* **i**: Italic
* **s**: Strikethrough
* **sub**: Subscript
* **sup**: Superscript
-* **small**: Makes font relatively smaller, equivalent to <span size="smaller">
+* **small**: Makes font relatively smaller, equivalent to `<span size="smaller">`
* **tt**: Monospace font
* **u**: Underline
diff --git a/docs/pango_rendering.md b/docs/pango_rendering.md
index a8fbd12b..0c0e3ba0 100644
--- a/docs/pango_rendering.md
+++ b/docs/pango_rendering.md
@@ -1,28 +1,25 @@
-
-# Pango Rendering
-
-The Pango rendering pipeline takes a string of Unicode characters and converts
-it into glyphs. This section describes the functions that implement the various
-stages of this pipeline.
+The Pango rendering pipeline takes a string of Unicode characters, converts them
+it into glyphs, and renders them on some output medium. This section describes the
+various stages of this pipeline and the APIs that implement them.
![Pango Rendering Pipeline](pipeline.png)
-* Itemization breaks a piece of text into segments with consistent direction
+* *Itemization* breaks a piece of text into segments with consistent direction
and shaping properies. Among other things, this determines which font to use
for each character. Use pango_itemize() or pango_itemize_with_base_dir()
to itemize text.
-* Shaping converts characters into glyphs. Use pango_shape(), pango_shape_full()
+* *Shaping* converts characters into glyphs. Use pango_shape(), pango_shape_full()
or pango_shape_with_flags() to shape text.
-* Line Breaking determines where line breaks should be inserted into a sequence
+* *Line Breaking* determines where line breaks should be inserted into a sequence
of glyphs. The function pango_break() determines possible line breaks. The
actual line breaking is done by PangoLayout.
-* Justification adjusts inter-word spacing to form lines of even length. This
+* *Justification* adjusts inter-word spacing to form lines of even length. This
is done by PangoLayout.
-* Rendering takes a string of positioned glyphs, and renders them onto a
+* *Rendering takes* a string of positioned glyphs, and renders them onto a
surface. This is accomplished by a PangoRenderer object. The functions
pango_cairo_show_glyph_string() and pango_cairo_show_layout() use a
PangoRenderer to draw text onto a cairo surface.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]