Closed
Bug 617203
Opened 14 years ago
Closed 12 years ago
"First character must be the start of a cluster ..." assertion failure with pango-graphite
Categories
(Core :: Layout: Text and Fonts, defect)
Tracking
()
RESOLVED
FIXED
People
(Reporter: karlt, Assigned: karlt)
Details
(Keywords: regression)
Attachments
(1 file)
http://hg.mozilla.org/mozilla-central/annotate/2b44a6a3bfd8/gfx/thebes/gfxFont.cpp#l3917 When pango-graphite is installed, it adds a PangoEngineLang, which changes the behavior of pango_break. The behaviour differs enough that it leads to failed assertions that the first character of a run begins a cluster, and it is not possible to move the cursor to the beginning of text if Graphite fonts are used. This is because Graphite's break does not set is_cursor_position for the position before the first character. STR: 1. Install pango-graphite and Dai Banna SIL Book http://scripts.sil.org/DaiBannaSIL 2. Copy 'ᦎᦷ ᦑᦺ' to the search bar. See assertion failures (with debug builds). 3. Try to use arrow keys to move cursor to beginning of the text. Fail.
Assignee | ||
Comment 1•14 years ago
|
||
I suspect assertions would fail even in very old builds. The cursor behavior is a regression since 2010-10-14.
Keywords: regression
Assignee | ||
Comment 2•14 years ago
|
||
I'm tempted to blacklist GraphiteEngineLang because it claims support for multiple scripts, but, for non-graphite fonts (Engine selection is not font-dependent), it merely runs the basic pango_default_break, overriding script-specific Engines - and it runs pango_default_break twice. See graphite_engine_break at http://scripts.sil.org/svn-public/graphite/graphite/trunk/wrappers/pangographite/silgraphite-break.c However, I think it is a bug in our code to rely on specific behavior from pango_break, and we should fix that. http://hg.mozilla.org/mozilla-central/annotate/2b44a6a3bfd8/gfx/thebes/gfxPangoFonts.cpp#l2571
Assignee | ||
Comment 3•14 years ago
|
||
Assignee: nobody → karlt
Attachment #495735 -
Flags: review?(jfkthame)
Comment 4•14 years ago
|
||
With the improvements we've made to gfxPlatform::SetupClusterBoundaries() (see bug 553981), do we really still need to be calling pango_break here, or could we remove the static SetupClusterBoundaries function from the gfxPangoFonts.cpp code altogether (thereby resolving both this and bug 614476)?
Assignee | ||
Comment 5•13 years ago
|
||
We now only call pango_break (this static SetupClusterBoundaries()) when using Pango for shaping. Pango's indic PangoEngineLangs has some special breaking rules that I assume gfxPlatform::SetupClusterBoundaries() does not handle, and it seems appropriate to use pango_break when using pango_shape (as I assume we do for indic scripts).
Assignee | ||
Comment 6•12 years ago
|
||
This code was removed in bug 703100.
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Updated•12 years ago
|
Attachment #495735 -
Flags: review?(jfkthame)
You need to log in
before you can comment on or make changes to this bug.
Description
•