diff options
Diffstat (limited to 'source/blender/blenkernel/intern/text.c')
-rw-r--r-- | source/blender/blenkernel/intern/text.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/source/blender/blenkernel/intern/text.c b/source/blender/blenkernel/intern/text.c index 3be9097ce82..86e7a152a4a 100644 --- a/source/blender/blenkernel/intern/text.c +++ b/source/blender/blenkernel/intern/text.c @@ -38,12 +38,12 @@ #include "MEM_guardedalloc.h" +#include "BLI_utildefines.h" #include "BLI_path_util.h" #include "BLI_string.h" #include "BLI_string_cursor_utf8.h" #include "BLI_string_utf8.h" #include "BLI_listbase.h" -#include "BLI_utildefines.h" #include "BLI_fileops.h" #include "DNA_constraint_types.h" @@ -936,7 +936,7 @@ void txt_move_right(Text *text, short sel) if (!sel) txt_pop_sel(text); } -void txt_jump_left(Text *text, short sel) +void txt_jump_left(Text *text, bool sel, bool use_init_step) { TextLine **linep; int *charp; @@ -948,12 +948,12 @@ void txt_jump_left(Text *text, short sel) BLI_str_cursor_step_utf8((*linep)->line, (*linep)->len, charp, STRCUR_DIR_PREV, - STRCUR_JUMP_DELIM); + STRCUR_JUMP_DELIM, use_init_step); if (!sel) txt_pop_sel(text); } -void txt_jump_right(Text *text, short sel) +void txt_jump_right(Text *text, bool sel, bool use_init_step) { TextLine **linep; int *charp; @@ -965,7 +965,7 @@ void txt_jump_right(Text *text, short sel) BLI_str_cursor_step_utf8((*linep)->line, (*linep)->len, charp, STRCUR_DIR_NEXT, - STRCUR_JUMP_DELIM); + STRCUR_JUMP_DELIM, use_init_step); if (!sel) txt_pop_sel(text); } @@ -2402,7 +2402,7 @@ void txt_delete_char(Text *text) void txt_delete_word(Text *text) { - txt_jump_right(text, 1); + txt_jump_right(text, true, true); txt_delete_sel(text); } @@ -2451,7 +2451,7 @@ void txt_backspace_char(Text *text) void txt_backspace_word(Text *text) { - txt_jump_left(text, 1); + txt_jump_left(text, true, true); txt_delete_sel(text); } |