Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDalai Felinto <dalai@blender.org>2020-06-09 08:05:10 +0300
committerJeroen Bakker <jeroen@blender.org>2020-07-29 11:05:58 +0300
commit9a4d51c5d98f1c661c475f54a3fa4e41735936ec (patch)
tree394dcea3b782404baa98b16d02f02cd0022adad1
parent322c67c9742b9c9a6ba216a28418288864c6bda3 (diff)
Fix T77609: Scale to Fit Text Box fails when text is too narrow
Caused by error in fix for T75965 (83d9ba341e5a).
-rw-r--r--source/blender/blenkernel/intern/font.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/font.c b/source/blender/blenkernel/intern/font.c
index 92eb6ea03e2..5b45a916834 100644
--- a/source/blender/blenkernel/intern/font.c
+++ b/source/blender/blenkernel/intern/font.c
@@ -1501,7 +1501,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;