Gets the logical and ink extents of a glyph within a font.
The coordinate system for each rectangle has its origin at the base line and horizontal origin of the character with increasing coordinates extending to the right and down. The macros PANGO_ASCENT(), PANGO_DESCENT(), PANGO_LBEARING(), and PANGO_RBEARING can be used to convert from the extents rectangle to more traditional font metrics. The units of the rectangles are in 1/PANGO_SCALE of a device unit.
Parameters:
glyph
The glyph index.
ink_rect
Rectangle used to store the extents of the glyph as drawn or 0 to indicate that the result is not needed.
logical_rect
Rectangle used to store the logical extents of the glyph or 0 to indicate that the result is not needed.
Since the metrics may be substantially different for different scripts, a language tag can be provided to indicate that the metrics should be retrieved that correspond to the script(s) used by that language.
Parameters:
language
Language tag used to determine which script to get the metrics for, or 0 to indicate to get the metrics for the entire font.
Returns:
A Pango::Metrics object. The caller must call pango_font_metrics_unref() when finished using the object.