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:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2009-02-17 22:55:20 +0300
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2009-02-17 22:55:20 +0300
commit38410b63a60a70faf0b82b6b2ec4172013dd2af1 (patch)
tree6be6707d1b0e5a7bebe81afbc57c807bf818f935 /source/blender/blenkernel/intern/font.c
parent8c8792bb127b0b1c33d35e78574e30fa29bd6279 (diff)
2.5: Text edit mode operators back. Took me a while getting
them nicely repeatable, and splitting up the big edit_text operator into individual operator so it's all nicely scriptable, documented, configurable, etc.. * Insert Text, Line Break, Insert Lorem * Toggle Case, Set Case, Toggle Style, Set Style, Set Material * Copy Text, Cut Text, Paste Text, Paste File, Paste Buffer * Move, Move Select, Delete * Change Spacing, Change Character Notes * Text (datablock) to Object doesn't work yet, will need to implement text editor context for that. * Some shortcut keys don't work because screen/wm overrides them, ctrl+x, ctrl+left/right. That override goes top down which works well for some cases, but here we need to override in the other direction. * There's no unicode support in RNA, or the user interface code for that matter, but text strings can contain these characters. At the moment it stores a UTF-8 string in char arrays, which is supposed to be nicely compatible with ascii. Seems reasonable to add support for UTF-8 in the interface code, python bindings, .. eventually?
Diffstat (limited to 'source/blender/blenkernel/intern/font.c')
-rw-r--r--source/blender/blenkernel/intern/font.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/source/blender/blenkernel/intern/font.c b/source/blender/blenkernel/intern/font.c
index 8f8a8fba983..ced8d3bdebb 100644
--- a/source/blender/blenkernel/intern/font.c
+++ b/source/blender/blenkernel/intern/font.c
@@ -658,7 +658,7 @@ struct chartrans *BKE_text_to_curve(Scene *scene, Object *ob, int mode)
VChar *che;
struct chartrans *chartransdata=NULL, *ct;
float *f, xof, yof, xtrax, linedist, *linedata, *linedata2, *linedata3, *linedata4;
- float twidth;
+ float twidth, maxlen= 0;
int i, slen, j;
int curbox;
int selstart, selend;
@@ -826,8 +826,6 @@ struct chartrans *BKE_text_to_curve(Scene *scene, Object *ob, int mode)
}
}
if(ascii== '\n' || ascii== '\r' || ascii==0 || ct->dobreak) {
- float maxlen;
-
ct->xof= xof;
ct->yof= yof;
ct->linenr= lnr;