| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
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.
|
| |
| |
| |
| |
| |
| |
| |
| | |
Use the new baseline-shift and font-scale attributes
to reimplement <sup> and <sub>.
Now they take font metrics into account and nest
properly.
|
| |
| |
| |
| |
| |
| |
| | |
Add a new font-scale attribute to indicate font size
changes due to super- and subscript shifts, and handle
it during item post-processing to find the right font
sizes.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Add a new baseline-shift attribute, which is similar to
rise, but accumulates. In addition, it supports font-
relative values such as superscript and subscript.
We implement support for this by computing baseline
shifts for run during line post-processing, and storing
them in the runs. The renderer now takes these shifts
into account when rendering layout lines.
|
| |
| |
| |
| |
| |
| | |
We are going to add new fields to PangoGlyphItem,
so zero-initialize the one we are allocating here
in ellipsize.c.
|
| |
| |
| |
| |
| | |
GTK needs this information to decide how to
render the glyphs, so provide it.
|
| | |
|
|/
|
|
|
| |
Now that we have a private class, we can retire
the misplaced vfunc in the fontmap class.
|
|
|
|
|
|
|
|
| |
Set a size on the font description returned by
pango_font_describe(). Otherwise, scaling it
doesn't work.
Fixes: #610
|
| |
|
|
|
|
| |
If we don't have them, just do the fallback.
|
|
|
|
|
|
| |
This variant of pango_glyph_string_index_to_x takes
log attrs so it does not have to compute them when
it needs them to determine grapheme boundaries.
|
|
|
|
|
|
|
|
|
|
| |
We need to take into account whether the characters
we are counting are actually cursor positions, else
we are bound to look for more carets than the font
has available, sometimes.
This change would benefit from passing log attrs into
pango_glyph_string_index_to_x.
|
|
|
|
| |
This is useful information.
|
|
|
|
| |
This has been broken all along. :(
|
|
|
|
| |
This broke the msvc build.
|
| |
|
| |
|
|
|
|
| |
Remove a few duplicated lines and typos.
|
|
|
|
|
| |
Instead of throwing away the log_widths array
for every run, keep it around and grow it as needed.
|
|\
| |
| |
| |
| | |
Keep offsets for items
See merge request GNOME/pango!451
|
| |
| |
| |
| | |
There is more we can do here, but this is a start.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Add a char_offset field to PangoItem, compute it as part of
itemization and update it when splitting items. Keeping this
number around cuts down on the amount of list and utf8 walking
we need to do later.
We have to do some extra shenanigans to preserve abi in the
face of pango's open-coded structs, so we introduce a
PangoItemPrivate type that is used internally. On 64bit,
PangoItem has a 4 byte whole, so we can keep the size of
PangoItemPrivate the same. No such luck on 32bit.
|
| |
| |
| |
| |
| |
| | |
Improve the itemization code to have all
variants take the same code paths, so we
can do fixups in one place.
|
|\ \
| | |
| | |
| | |
| | |
| | |
| | | |
renderer: Use ink rects for line lengths
Closes #139
See merge request GNOME/pango!448
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When rendering underlines and the like, we should use
ink extents, since the logical extents will get shortened
by kerning, which can be pretty noticable when underlining
individual glyphs, such as the T in To.
Fixes: #139
|
| | | |
|
| | | |
|
| |/
|/| |
|
|/
|
|
|
|
| |
The intention was to flip the rectangle horizontally.
We do return a negative width, but we forgot to flip
the origin.
|
| |
|
|
|
|
|
|
|
| |
Try to find a single non-mark glyph in a multi-glyph
cluster to use its ligature caret information. This
fixes situations in Arabic where you can have marks
on top of ligatures, e.g. ﻉﻭ.
|
|
|
|
|
|
|
| |
The ligature caret positions returned by
hb_ot_layout_get_ligature_carets are 'unshaped' metrics.
We need to take the kerning into account that is applied
during shaping, and shows up in the glyphstring as x_offset.
|
|
|
|
| |
Still not working quite right, but getting closer.
|
|
|
|
|
|
| |
What the docs were saying is no longer strictly true,
now that we are using font metrics. Update them, and
add an illustration.
|
|
|
|
| |
Show cursor positions.
|
|
|
|
|
|
|
| |
We were not correctly handling overlapping segments
in all cases, with <span segment='word'>. Improve this.
Update affected tests.
|
|
|
|
|
|
| |
We were not correctly handling the case where
wipe out a sentence boundary after the fact,
and were leaving behind a stray sentence end.
|
|
|
|
| |
These are required for a conforming implementation.
|
|
|
|
|
|
|
|
| |
We were not putting a line break at the end of the
text, in cases where a paragraph ends with a newline.
Enforce this in all break apis.
Update affected tests.
|
|\
| |
| |
| |
| |
| |
| | |
Use ligature caret lists
Closes #39
See merge request GNOME/pango!438
|
| |
| |
| |
| |
| |
| |
| |
| | |
Some fonts provide information about where to
place carets inside ligatures. Use it, when it
is available.
Fixes: #39
|
|/
|
|
|
|
|
| |
We were forgetting to reshape runs in some situations,
leading to them not having hyphens appended. This was
happening when runs fit fully onto the end of a line
that is wrapped anyway.
|
|
|
|
|
|
|
| |
Add attributes that let us override word and
sentence boundaries (and, indirectly, line breaks).
Tests included.
|
|\
| |
| |
| |
| |
| |
| | |
Add hyphens to log attrs
Closes #603
See merge request GNOME/pango!436
|
| |
| |
| |
| |
| |
| | |
Print out all the log attrs we have.
Update expected test outputs.
|
| |
| |
| |
| |
| |
| |
| |
| | |
Replace ‧ and | with a - when we break there.
Update affected test output.
Fixes: #603
|
| |
| |
| |
| |
| | |
Rearrange the buffer setup code slightly,
so that we can change it easier, later.
|
| | |
|
| |
| |
| |
| |
| |
| | |
The code computing this is much better off in break.c,
so move it there, and keep the information in the
log attr array.
|