softwrap: use smooth scrolling when softwrapping is toggled on
If the cursor is near the bottom row when softwrap gets switched on, the screen should scroll just the amount needed to keep the cursor onscreen. This fixes https://savannah.gnu.org/bugs/?56317. Bug existed since softwrapping was introduced in version 2.1.11.master
parent
8f1cd50f1e
commit
0ebfd54e17
|
@ -1360,7 +1360,9 @@ void do_toggle(int flag)
|
|||
signal_init();
|
||||
break;
|
||||
case SOFTWRAP:
|
||||
if (!ISSET(SOFTWRAP))
|
||||
if (ISSET(SOFTWRAP))
|
||||
edit_redraw(openfile->current, FLOWING);
|
||||
else
|
||||
openfile->firstcolumn = 0;
|
||||
refresh_needed = TRUE;
|
||||
break;
|
||||
|
|
Loading…
Reference in New Issue