mirror of
https://github.com/labwc/labwc.git
synced 2026-04-03 07:15:34 -04:00
clients/labnag.c: return zero on get_text_size() error
Ref: https://github.com/swaywm/sway/pull/9070
This commit is contained in:
parent
9a8154836c
commit
46d687ab54
1 changed files with 10 additions and 0 deletions
|
|
@ -206,6 +206,16 @@ static void
|
|||
get_text_size(cairo_t *cairo, const PangoFontDescription *desc, int *width, int *height,
|
||||
int *baseline, double scale, bool markup, const char *fmt, ...)
|
||||
{
|
||||
if (width) {
|
||||
*width = 0;
|
||||
}
|
||||
if (height) {
|
||||
*height = 0;
|
||||
}
|
||||
if (baseline) {
|
||||
*baseline = 0;
|
||||
}
|
||||
|
||||
va_list args;
|
||||
va_start(args, fmt);
|
||||
gchar *buf = g_strdup_vprintf(fmt, args);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue