diff --git a/4coder_default_include.cpp b/4coder_default_include.cpp index 30c86054..4292b34b 100644 --- a/4coder_default_include.cpp +++ b/4coder_default_include.cpp @@ -705,6 +705,7 @@ write_string(Application_Links *app, String string){ app->buffer_replace_range(app, &buffer, view.cursor.pos, view.cursor.pos, string.str, string.size); + app->view_set_cursor(app, &view, seek_pos(view.cursor.pos + string.size), true); } CUSTOM_COMMAND_SIG(write_increment){ diff --git a/4ed.cpp b/4ed.cpp index ba1f4b21..7b050b75 100644 --- a/4ed.cpp +++ b/4ed.cpp @@ -468,6 +468,7 @@ COMMAND_DECL(word_complete){ if (search_hit_add(general, &complete_state->hits, &complete_state->str, spare, match_size)){ view_replace_range(system, models, view, word_start, word_end, spare, match_size); + view_cursor_move(view, word_start + match_size); complete_state->word_end = word_start + match_size; complete_state->set.ranges[1].start = word_start + match_size; @@ -486,6 +487,7 @@ COMMAND_DECL(word_complete){ match_size = complete_state->iter.word.size; view_replace_range(system, models, view, word_start, word_end, complete_state->iter.word.str, match_size); + view_cursor_move(view, word_start + match_size); complete_state->word_end = word_start + match_size; complete_state->set.ranges[1].start = word_start + match_size; diff --git a/README.txt b/README.txt index 242c4bfc..c984fd26 100644 --- a/README.txt +++ b/README.txt @@ -1,4 +1,4 @@ -Distribution Date: 5.7.2016 (dd.mm.yyyy) +Distribution Date: 6.7.2016 (dd.mm.yyyy) Thank you for contributing to the 4coder project! diff --git a/SUPERREADME.txt b/SUPERREADME.txt index c13cb934..65b2e155 100644 --- a/SUPERREADME.txt +++ b/SUPERREADME.txt @@ -1,4 +1,4 @@ -Distribution Date: 5.7.2016 (dd.mm.yyyy) +Distribution Date: 6.7.2016 (dd.mm.yyyy) Thank you for contributing to the 4coder project!