diff options
author | Dalai Felinto <dalai@blender.org> | 2020-06-09 08:05:10 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2020-06-09 08:07:59 +0300 |
commit | 70a27d0a638665007b45e5d80d2f758d25ed246b (patch) | |
tree | 41dccb581f0433a6465ef1cc3320ef9d510913f5 /source/blender/blenkernel/intern/font.c | |
parent | f326b6a18eaba86c39d63a8b1c62a3e6ef0712cd (diff) |
Fix T77609: Scale to Fit Text Box fails when text is too narrow
Caused by error in fix for T75965 (83d9ba341e5a).
Diffstat (limited to 'source/blender/blenkernel/intern/font.c')
-rw-r--r-- | source/blender/blenkernel/intern/font.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/font.c b/source/blender/blenkernel/intern/font.c index 54f2492af93..34bb328bde0 100644 --- a/source/blender/blenkernel/intern/font.c +++ b/source/blender/blenkernel/intern/font.c @@ -1502,7 +1502,7 @@ static bool vfont_to_curve(Object *ob, } else if (tb_scale.h == 0.0f) { /* This is a horizontal overflow. */ - if (longest_line_length != 0.0f) { + if (longest_line_length > 0.0f) { /* We make sure longest line before it broke can fit here. */ float scale_to_fit = tb_scale.w / longest_line_length; scale_to_fit -= FLT_EPSILON; |