https://bugzilla.redhat.com/show_bug.cgi?id=1036351
Nils Philippsen nphilipp@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |fonts-bugs@lists.fedoraproj | |ect.org, | |i18n-bugs@lists.fedoraproje | |ct.org, tagoh@redhat.com Component|gimp |pango Assignee|nphilipp@redhat.com |tagoh@redhat.com
--- Comment #11 from Nils Philippsen nphilipp@redhat.com --- Looks like a division by zero here:
--- 8< --- pango/pango-layout.c:6098 -- pango_layout_iter_get_char_extents() --- x0 = (iter->character_position * cluster_rect.width) / iter->cluster_num_chars; --- >8 ---
The cluster_num_chars member is opaque to outside API users, so IMO has to be set by pango itself:
--- 8< --- app/tools/gimptexttool.c:841 -- gimp_text_tool_draw_selection() --- iter = pango_layout_get_iter (layout);
gimp_draw_tool_push_group (draw_tool, fill_group);
do { if (! pango_layout_iter_get_run (iter)) continue;
i = pango_layout_iter_get_index (iter);
if (i >= min && i < max) { PangoRectangle rect; gint ytop, ybottom;
pango_layout_iter_get_char_extents (iter, &rect); pango_layout_iter_get_line_yrange (iter, &ytop, &ybottom);
rect.y = ytop; rect.height = ybottom - ytop;
pango_extents_to_pixels (&rect, NULL);
gimp_text_layout_transform_rect (text_tool->layout, &rect);
rect.x += offset_x; rect.y += offset_y;
gimp_draw_tool_add_rectangle (draw_tool, TRUE, rect.x, rect.y, rect.width, rect.height); } } while (pango_layout_iter_next_char (iter)); --- >8 ---
Changing component to pango.
i18n-bugs@lists.fedoraproject.org