forked from bartvdbraak/blender
Bugfix: Transform autokey warning indicator text was getting clipped prematurely
After quite some time debugging going back through previous commits for this feature and digging around the internals of the blenfont,I finally found the culprit. It turns out that there was just a single line missing between BLF_width_default() and BLF_width_and_height_default(), which caused the widths returned to understimate the space required or so, causing text clipping. The offending line probably correcting for different DPI scaling values.
This commit is contained in:
parent
8a7ce9c924
commit
67e54eb819
@ -619,6 +619,7 @@ void BLF_width_and_height_default(const char *str, float *width, float *height)
|
||||
return;
|
||||
}
|
||||
|
||||
BLF_size(global_font_default, global_font_points, global_font_dpi);
|
||||
BLF_width_and_height(global_font_default, str, width, height);
|
||||
}
|
||||
|
||||
|
@ -1685,7 +1685,7 @@ static void drawTransformView(const struct bContext *C, ARegion *UNUSED(ar), voi
|
||||
static void drawAutoKeyWarning(TransInfo *UNUSED(t), ARegion *ar)
|
||||
{
|
||||
rcti rect;
|
||||
const char *printable = IFACE_("Auto Keying On");
|
||||
const char printable[] = IFACE_("Auto Keying On");
|
||||
float printable_size[2];
|
||||
int xco, yco;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user