mirror of
https://github.com/labwc/labwc.git
synced 2025-11-04 13:30:07 -05:00
src/osd.c: fix max text width
Making sure long window titles don't overflow the selection box Closes issue #406 Written-by: @johanmalm
This commit is contained in:
parent
ca56357b5f
commit
1eab4b5269
1 changed files with 2 additions and 1 deletions
|
|
@ -189,7 +189,8 @@ osd_update(struct server *server)
|
|||
/* text */
|
||||
set_source(cairo, theme->osd_label_text_color);
|
||||
PangoLayout *layout = pango_cairo_create_layout(cairo);
|
||||
pango_layout_set_width(layout, w * PANGO_SCALE);
|
||||
pango_layout_set_width(layout,
|
||||
(OSD_ITEM_WIDTH - 2 * OSD_ITEM_PADDING) * PANGO_SCALE);
|
||||
pango_layout_set_ellipsize(layout, PANGO_ELLIPSIZE_END);
|
||||
|
||||
struct font font = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue