Skip to content
Commit 909c7bca authored by Raph Levien's avatar Raph Levien
Browse files

Fix measurement to respect grapheme and span boundaries

When measuring in TextLine (important for cursor positioning), the
substring measured must neither be too short (it can't just be the
substring up to the measure limit, but must include additional
characters if they form a ligature) nor too long (it can't extend
beyond the end of the CharacterStyle span, otherwise the measurement
fails to account for the fact that the CharacterStyle span boundary
breaks the ligature). This patch gets it just right.

Bug: 25375561
Change-Id: I36e1c4bdc66424d3b611cf54031756cf54cf3fec
parent d3b2826a
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment