[pango/gi-docs: 72/74] docs: Convert xft section to pango_xft.md




commit cd5876687285bb0583d38b25f7cb08bb93ae8cf0
Author: Matthias Clasen <mclasen redhat com>
Date:   Mon Feb 22 16:11:48 2021 -0500

    docs: Convert xft section to pango_xft.md

 docs/pango_xft.md     | 26 ++++++++++++++++++++++++++
 docs/pangoxft.toml.in |  3 +++
 pango/pangoxft-font.c | 30 ------------------------------
 3 files changed, 29 insertions(+), 30 deletions(-)
---
diff --git a/docs/pango_xft.md b/docs/pango_xft.md
new file mode 100644
index 00000000..340506d2
--- /dev/null
+++ b/docs/pango_xft.md
@@ -0,0 +1,26 @@
+Title: Xft Fonts and Rendering
+
+The Xft library is a library for displaying fonts on the X window
+system; internally it uses the fontconfig library to locate font
+files, and the FreeType library to load and render fonts. The
+Xft backend is the recommended Pango font backend for screen
+display with X. (The Cairo back end is another possibility.)
+
+Using the Xft backend is generally straightforward;
+[func@PangoXft.get_context] creates a context for a specified display
+and screen. You can then create a [class@Pango.Layout] with that context
+and render it with [func@PangoXft.render_layout]. At a more advanced
+level, the low-level fontconfig options used for rendering fonts
+can be affected using [func@PangoXft.set_default_substitute], and
+[func@PangoXft.substitute_changed].
+
+A range of functions for drawing pieces of a layout, such as individual
+layout lines and glyphs strings are provided.  You can also directly
+create a [class@PangoXft.Renderer]. Finally, in some advanced cases,
+it is useful to derive from [class@PangoXft.Renderer]. Deriving from
+[class@PangoXft.Renderer] is useful for two reasons. One reason is be
+to support custom attributes by overriding `PangoRendererClass` virtual
+functions like 'prepare_run' or 'draw_shape'. The other reason is to
+customize exactly how the final bits are drawn to the destination by
+overriding the `PangoXftRendererClass` virtual functions
+'composite_glyphs' and 'composite_trapezoids'.
diff --git a/docs/pangoxft.toml.in b/docs/pangoxft.toml.in
index fa3b1494..d5285e6e 100644
--- a/docs/pangoxft.toml.in
+++ b/docs/pangoxft.toml.in
@@ -28,6 +28,9 @@ show_index_summary = true
 base_url = "https://gitlab.gnome.org/GNOME/pango/-/blob/master/";
 
 [extra]
+content_files = [
+  "pango_xft.md"
+]
 
 content_images = [
   "pango-name.png"
diff --git a/pango/pangoxft-font.c b/pango/pangoxft-font.c
index 38198bc0..ac4e6f39 100644
--- a/pango/pangoxft-font.c
+++ b/pango/pangoxft-font.c
@@ -19,36 +19,6 @@
  * Boston, MA 02111-1307, USA.
  */
 
-/**
- * SECTION:xft-fonts
- * @short_description:Font handling and rendering with the Xft backend
- * @title:Xft Fonts and Rendering
- *
- * The Xft library is a library for displaying fonts on the X window
- * system; internally it uses the fontconfig library to locate font
- * files, and the FreeType library to load and render fonts. The
- * Xft backend is the recommended Pango font backend for screen
- * display with X. (The <link linkend="pango-Cairo-Rendering">Cairo back end</link> is another possibility.)
- *
- * Using the Xft backend is generally straightforward;
- * pango_xft_get_context() creates a context for a specified display
- * and screen. You can then create a #PangoLayout with that context
- * and render it with pango_xft_render_layout(). At a more advanced
- * level, the low-level fontconfig options used for rendering fonts
- * can be affected using pango_xft_set_default_substitute(), and
- * pango_xft_substitute_changed().
- *
- * A range of functions for drawing pieces of a layout, such as
- * individual layout lines and glyphs strings are provided.  You can also
- * directly create a #PangoXftRenderer. Finally, in some advanced cases, it
- * is useful to derive from #PangoXftRenderer. Deriving from
- * #PangoXftRenderer is useful for two reasons. One reason is be to
- * support custom attributes by overriding #PangoRendererClass virtual
- * functions like 'prepare_run' or 'draw_shape'. The reason is to
- * customize exactly how the final bits are drawn to the destination by
- * overriding the #PangoXftRendererClass virtual functions
- * 'composite_glyphs' and 'composite_trapezoids'.
- */
 #include "config.h"
 
 #include <stdlib.h>


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]