softwrap: realign start-of-screen when redoing an automatic hard-wrap

Redoing an automatic hard-wrap while one or more chunks of the affected
line are offscreen, can leave 'firstcolumn' with a value that doesn't
fit the situation.  So, make sure that it has a valid value.

This complements the previous commit.

This fixes https://savannah.gnu.org/bugs/?65611.
The issue was reported by `correctmost`.

Bug existed since version 2.8.6, commit e375995d.
This commit is contained in:
Benno Schulenberg 2024-04-19 16:02:32 +02:00
parent 7b07e1ee5c
commit 5beb14cffe

View File

@ -759,6 +759,7 @@ void do_redo(void)
do_redo();
u = openfile->current_undo;
goto_line_posx(u->head_lineno, u->head_x);
ensure_firstcolumn_is_aligned();
break;
case SPLIT_END:
redidmsg = _("addition");