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:
authorCampbell Barton <ideasman42@gmail.com>2014-05-16 04:27:52 +0400
committerCampbell Barton <ideasman42@gmail.com>2014-05-16 04:32:29 +0400
commitbe980b9f7d6443e27e1263259430dc0b563d59d8 (patch)
tree4b12cc4be0d5ad697dee1b133de368aa18167349 /source/blender/blenkernel/intern/curve.c
parent57e1ec23088f2a4a16bdd27c301e2ffd8bee6cb1 (diff)
3D Text: Change textbox placement to ignore font scale
Logic here was very stupid, texboxes would have their initial locations scaled by font size but not their width/height. Now its possible to change font size while keeping the textbox layout. Other fixes - tab character didn't work properly with textboxes. - memory leak when VFontData was missing.
Diffstat (limited to 'source/blender/blenkernel/intern/curve.c')
-rw-r--r--source/blender/blenkernel/intern/curve.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/blenkernel/intern/curve.c b/source/blender/blenkernel/intern/curve.c
index 96087e416dd..fa5e3dc24c3 100644
--- a/source/blender/blenkernel/intern/curve.c
+++ b/source/blender/blenkernel/intern/curve.c
@@ -4229,8 +4229,8 @@ void BKE_curve_material_index_clear(Curve *cu)
void BKE_curve_rect_from_textbox(const struct Curve *cu, const struct TextBox *tb, struct rctf *r_rect)
{
- r_rect->xmin = (cu->xof * cu->fsize) + tb->x;
- r_rect->ymax = (cu->yof * cu->fsize) + tb->y + cu->fsize;
+ r_rect->xmin = cu->xof + tb->x;
+ r_rect->ymax = cu->yof + tb->y + cu->fsize;
r_rect->xmax = r_rect->xmin + tb->w;
r_rect->ymin = r_rect->ymax - tb->h;