[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Bug#987587: libpango1.0-udeb: hangs the installer in various situations



On Mon, 03 May 2021 at 17:17:21 +0100, Simon McVittie wrote:
> I've also been able to attach a debugger to debconf. My preliminary finding
> is: we enter gtk_container_idle_sizer() in GTK 2 and never exit, because
> every time we go into gtk_container_check_resize(), we end up in
> gtk_text_layout_emit_changed() which emits a signal that eventually calls
> _gtk_container_queue_resize(), so gtk_container_idle_sizer() has more work
> to do and we loop indefinitely.
...
> My next step is going to be to try to hack Harfbuzz to disable the Indic
> shaper (which is what seems to be in use here) and see whether that stops
> the infinite loop. That's unlikely to be an acceptable solution, but it'll
> at least tell us whether the Indic shaper is what's triggering this.

Yes, this worked! If I disable the Indic shaper with the attached hack,
that seems to be enough to make installation proceed.

Again, this is probably not an acceptable solution: Harfbuzz has shapers
for complex scripts for a reason, and I suspect someone who can speak
the relevant language would find the text either ugly or unreadable
when using the default shaper. However, I hope this does at least point
someone who knows more about the mechanics of text rendering and/or GTK
relayout in the right direction...

I think the reason this regressed between Pango 1.43.0 and 1.44.0 might
just be that Pango 1.44.0 uses Harfbuzz to implement more of its own
functionality.

    smcv
From: Simon McVittie <smcv@debian.org>
Date: Mon, 3 May 2021 17:02:50 +0100
Subject: HACK: Disable Indic shaper

This appears to trigger a relayout loop in GTK 2 in the d-i environment.

Bug-Debian: https://bugs.debian.org/987587
---
 src/hb-ot-shape-complex.hh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/hb-ot-shape-complex.hh b/src/hb-ot-shape-complex.hh
index a1a7a6a..6c82b87 100644
--- a/src/hb-ot-shape-complex.hh
+++ b/src/hb-ot-shape-complex.hh
@@ -263,7 +263,7 @@ hb_ot_shape_complex_categorize (const hb_ot_shape_planner_t *planner)
       else if ((planner->map.chosen_script[0] & 0x000000FF) == '3')
 	return &_hb_ot_complex_shaper_use;
       else
-	return &_hb_ot_complex_shaper_indic;
+	return &_hb_ot_complex_shaper_default;
 
     case HB_SCRIPT_KHMER:
 	return &_hb_ot_complex_shaper_khmer;

Reply to: