Fix T44470: File Selection sometimes surpresses last Character.
Tweak hack of `file_draw_string()` (there may be better solution, but not worth spending time on this, the whole filebrowser drawing code is to be rewritten anyway).
This commit is contained in:
parent
e1a53b6d52
commit
4da050674e
Notes:
blender-bot
2023-02-14 09:13:10 +01:00
Referenced by issue #44470, File Selection sometimes surpresses last Character
|
@ -307,10 +307,10 @@ static void file_draw_string(int sx, int sy, const char *string, float width, in
|
|||
|
||||
/* no text clipping needed, UI_fontstyle_draw does it but is a bit too strict (for buttons it works) */
|
||||
rect.xmin = sx;
|
||||
rect.xmax = (int)(sx + ceil(width + 4.0f));
|
||||
rect.xmax = (int)(sx + ceil(width + 5.0f / UI_DPI_FAC));
|
||||
rect.ymin = sy - height;
|
||||
rect.ymax = sy;
|
||||
|
||||
|
||||
UI_fontstyle_draw(&fs, &rect, fname);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue