[Bf-blender-cvs] [a1e7d96801d] blender-v3.4-release: Fix T102213: Invalid font size in the image editor with some scripts

nutti noreply at git.blender.org
Fri Dec 16 16:03:32 CET 2022


Commit: a1e7d96801d8644e9f552b731eeba8ba5f2ccfd6
Author: nutti
Date:   Wed Dec 14 15:40:53 2022 +1100
Branches: blender-v3.4-release
https://developer.blender.org/rBa1e7d96801d8644e9f552b731eeba8ba5f2ccfd6

Fix T102213: Invalid font size in the image editor with some scripts

The size could be left at an unexpected value by scripts, causing
the wrong size to be shown.

Ref D16493

===================================================================

M	source/blender/editors/screen/area.c

===================================================================

diff --git a/source/blender/editors/screen/area.c b/source/blender/editors/screen/area.c
index a62e027ba03..af97b37acc1 100644
--- a/source/blender/editors/screen/area.c
+++ b/source/blender/editors/screen/area.c
@@ -3531,6 +3531,9 @@ void ED_region_info_draw_multiline(ARegion *region,
   /* background box */
   rcti rect = *ED_region_visible_rect(region);
 
+  /* Needed in case scripts leave the font size at an unexpected value, see: T102213. */
+  BLF_size(fontid, style->widget.points * U.dpi_fac);
+
   /* Box fill entire width or just around text. */
   if (!full_redraw) {
     const char **text = &text_array[0];



More information about the Bf-blender-cvs mailing list