oops; only work around the problem of the mark's being in the middle of
a spell checked word if the mark was on in the first place git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@2071 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
Этот коммит содержится в:
родитель
90e59c1a18
Коммит
46c604a14e
25
src/nano.c
25
src/nano.c
@ -1541,7 +1541,7 @@ bool do_int_spell_fix(const char *word)
|
|||||||
/* TRUE if (mark_beginbuf, mark_beginx) is the top of the mark,
|
/* TRUE if (mark_beginbuf, mark_beginx) is the top of the mark,
|
||||||
* FALSE if (current, current_x) is. */
|
* FALSE if (current, current_x) is. */
|
||||||
filestruct *top, *bot;
|
filestruct *top, *bot;
|
||||||
size_t top_x, bot_x, bot_data_len;
|
size_t top_x, bot_x;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Make sure spell-check is case sensitive. */
|
/* Make sure spell-check is case sensitive. */
|
||||||
@ -1617,15 +1617,20 @@ bool do_int_spell_fix(const char *word)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* If the mark ended in the middle of a word and that word was
|
#ifndef NANO_SMALL
|
||||||
* spell-checked, put either current_x_save or mark_beginx,
|
if (old_mark_set) {
|
||||||
* depending on the value of right_side_up, at the end of the
|
size_t bot_data_len = strlen(filebot->data);
|
||||||
* spell-checked word. */
|
|
||||||
bot_data_len = strlen(filebot->data);
|
/* If the mark ended in the middle of a word and that word was
|
||||||
if (right_side_up)
|
* spell-checked, put either current_x_save or mark_beginx,
|
||||||
current_x_save = bot_data_len;
|
* depending on the value of right_side_up, at the end of the
|
||||||
else
|
* spell-checked word. */
|
||||||
mark_beginx = bot_data_len;
|
if (right_side_up)
|
||||||
|
current_x_save = bot_data_len;
|
||||||
|
else
|
||||||
|
mark_beginx = bot_data_len;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Restore the search/replace strings. */
|
/* Restore the search/replace strings. */
|
||||||
free(last_search);
|
free(last_search);
|
||||||
|
Загрузка…
Ссылка в новой задаче
Block a user