summaryrefslogtreecommitdiff
path: root/pango/pango-layout-private.h
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2021-08-29 17:26:52 -0400
committerMatthias Clasen <mclasen@redhat.com>2021-08-31 14:29:56 -0400
commit1f0b5d5b87b61a37bebd393c0d67cce0b4ccdcb9 (patch)
tree1d9e1e3586a1f3b907385aa1c22a4c3456f147e4 /pango/pango-layout-private.h
parent1b73eedc69bc15941f216bff11817b825adb51d8 (diff)
downloadpango-1f0b5d5b87b61a37bebd393c0d67cce0b4ccdcb9.tar.gz
Add horizontal displacement
Apply horizontal displacements for superscripts and subscripts that are provided in font metrics. This noticably improves the placement of superscripts in italics. Currently, we only apply these displacements in post-processing, and ignore the width changes during line-breaking. This could be improved by moving the baseline handling into the line-breaking proper.
Diffstat (limited to 'pango/pango-layout-private.h')
-rw-r--r--pango/pango-layout-private.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/pango/pango-layout-private.h b/pango/pango-layout-private.h
index 1805e730..b9f9b137 100644
--- a/pango/pango-layout-private.h
+++ b/pango/pango-layout-private.h
@@ -112,11 +112,12 @@ struct _PangoLayoutIter
Extents *line_extents;
int line_index;
- /* X position of the current run */
+ /* Position of the current run */
int run_x;
- /* Width of the current run */
+ /* Width and end offset of the current run */
int run_width;
+ int end_x_offset;
/* this run is left-to-right */
gboolean ltr;