FontMetrics
Object Hierarchy:
Pango.FontMetrics
Pango.FontMetrics
Pango.FontMetrics
Description:
[ CCode ( ref_function = "pango_font_metrics_ref" , type_id = "pango_font_metrics_get_type ()" , unref_function = "pango_font_metrics_unref" ) ] [ Compact ]public class FontMetrics
A `PangoFontMetrics` structure holds the overall metric information for a font.
The information in a `PangoFontMetrics` structure may be restricted to a script. The fields of this structure are private to
implementations of a font backend. See the documentation of the corresponding getters for documentation of their meaning.
For an overview of the most important metrics, see:
<picture> <source srcset="fontmetrics-dark.png" media="(prefers-color-scheme: dark)"> <img alt="Font metrics"
src="fontmetrics-light.png"> </picture>
Content:
Methods:
public unowned FontMetrics ? @ref ()
Increase the reference count of a font metrics structure by one.
public int get_approximate_char_width ()
Gets the approximate character width for a font metrics structure.
public int get_approximate_digit_width ()
Gets the approximate digit width for a font metrics structure.
public int get_ascent ()
Gets the ascent from a font metrics structure.
public int get_descent ()
Gets the descent from a font metrics structure.
public int get_height ()
Gets the line height from a font metrics structure.
public int get_strikethrough_position ()
Gets the suggested position to draw the strikethrough.
public int get_strikethrough_thickness ()
Gets the suggested thickness to draw for the strikethrough.
public int get_underline_position ()
Gets the suggested position to draw the underline.
public int get_underline_thickness ()
Gets the suggested thickness to draw for the underline.
public void unref ()
Decrease the reference count of a font metrics structure by one.