mirror of
https://github.com/lbonn/rofi
synced 2024-11-10 14:24:27 +00:00
Fall back to integer setting for distance
This commit is contained in:
parent
7b0e0643c8
commit
fb2d8b37a6
1 changed files with 5 additions and 0 deletions
|
@ -259,6 +259,11 @@ Distance rofi_theme_get_distance ( const char *wclass, const char *name, const
|
|||
if ( p ){
|
||||
return p->value.padding.left;
|
||||
}
|
||||
// Fall back to px if no metric is given.
|
||||
p = rofi_theme_find_property ( widget, P_INTEGER, property );
|
||||
if ( p ){
|
||||
return (Distance){(double)p->value.i, PW_PX};
|
||||
}
|
||||
return (Distance){def, PW_PX};
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue