diff options
author | Campbell Barton <ideasman42@gmail.com> | 2013-01-16 07:30:40 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2013-01-16 07:30:40 +0400 |
commit | c42054762530d2ca347078a8d70cd9eac379439d (patch) | |
tree | bb26d60ce2b779916d72914eecba221d82cab15f /source/blender/editors/space_text | |
parent | e18f90617b4c5525b84a1b6304097725b8978c21 (diff) |
correction to last commit
Diffstat (limited to 'source/blender/editors/space_text')
-rw-r--r-- | source/blender/editors/space_text/text_format_py.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/source/blender/editors/space_text/text_format_py.c b/source/blender/editors/space_text/text_format_py.c index cd9d45c5b0e..45a8b6bf646 100644 --- a/source/blender/editors/space_text/text_format_py.c +++ b/source/blender/editors/space_text/text_format_py.c @@ -233,7 +233,7 @@ static void txtfmt_py_format_line(SpaceText *st, TextLine *line, const int do_ne /* Deal with comments first */ if (*str == '#') { /* fill the remaining line */ - text_format_fill(&str, &fmt, prev, len - (int)(str - fs.buf)); + text_format_fill(&str, &fmt, FMT_TYPE_COMMENT, len - (int)(str - fs.buf)); } else if (*str == '"' || *str == '\'') { /* Strings */ @@ -259,8 +259,7 @@ static void txtfmt_py_format_line(SpaceText *st, TextLine *line, const int do_ne /* Booleans */ else if (prev != FMT_TYPE_DEFAULT && (i = txtfmt_py_find_bool(str)) != -1) { if (i > 0) { - memset(fmt, FMT_TYPE_NUMERAL, i); - i--; fmt += i; str += i; + text_format_fill(&str, &fmt, FMT_TYPE_NUMERAL, i); } else { str += BLI_str_utf8_size_safe(str) - 1; |