mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Bug #467529: Fix Align_n by specifying pango widths and ellipse modes for check print texts.
This patch from David Reiser reverts r16475, but by using pango_layout_set_ellipsize() center or right aligned texts are printed correctly and the first line is stilled showed instead of the last one. BP git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@17127 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
b4d3f97c53
commit
db91a80c93
@ -1363,7 +1363,8 @@ draw_text(GncPrintContext * context, const gchar * text, check_item_t * data,
|
|||||||
}
|
}
|
||||||
pango_layout_set_alignment(layout,
|
pango_layout_set_alignment(layout,
|
||||||
data->w ? data->align : PANGO_ALIGN_LEFT);
|
data->w ? data->align : PANGO_ALIGN_LEFT);
|
||||||
pango_layout_set_width(layout, -1);
|
pango_layout_set_width(layout, data->w ? data->w * PANGO_SCALE : -1);
|
||||||
|
pango_layout_set_ellipsize(layout, PANGO_ELLIPSIZE_END);
|
||||||
if (gnc_gconf_get_bool(GCONF_SECTION, KEY_BLOCKING_CHARS, NULL)) {
|
if (gnc_gconf_get_bool(GCONF_SECTION, KEY_BLOCKING_CHARS, NULL)) {
|
||||||
new_text = g_strdup_printf("***%s***", text);
|
new_text = g_strdup_printf("***%s***", text);
|
||||||
pango_layout_set_text(layout, new_text, -1);
|
pango_layout_set_text(layout, new_text, -1);
|
||||||
|
Loading…
Reference in New Issue
Block a user