oops; Pico's adding a new magicline unconditionally when uncutting
leaves the cursor on the current magicline is actually consistent (and hence not a bug), so duplicate that behavior again git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@2130 35c25a1d-7b9e-4130-9fde-d3aeb78583b8master
parent
6e738ac712
commit
cc89513f14
|
@ -16,10 +16,6 @@ CVS code -
|
||||||
do_cut_text()
|
do_cut_text()
|
||||||
- If keep_cutbuffer is FALSE, only blow away the text in the
|
- If keep_cutbuffer is FALSE, only blow away the text in the
|
||||||
cutbuffer if the cutbuffer isn't empty. (DLR)
|
cutbuffer if the cutbuffer isn't empty. (DLR)
|
||||||
do_uncut_text()
|
|
||||||
- No longer duplicate Pico's adding an extra magicline to the
|
|
||||||
file if uncutting leaves the cursor on the current one, as
|
|
||||||
it's actually a bug. (DLR)
|
|
||||||
- global.c:
|
- global.c:
|
||||||
shortcut_init()
|
shortcut_init()
|
||||||
- Fix misplaced #endif keeping the "Full Justify" shortcut in
|
- Fix misplaced #endif keeping the "Full Justify" shortcut in
|
||||||
|
|
10
src/cut.c
10
src/cut.c
|
@ -156,9 +156,17 @@ void do_uncut_text(void)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
/* Add a copy of the text in the cutbuffer to the current filestruct
|
/* Add a copy of the text in the cutbuffer to the current filestruct
|
||||||
* at the current cursor position. */
|
* at the current cursor position. Note that if the text in the
|
||||||
|
* cutbuffer doesn't end in a newline and the current cursor
|
||||||
|
* position is on the magicline, a new magicline will be added. */
|
||||||
copy_from_filestruct(cutbuffer, cutbottom);
|
copy_from_filestruct(cutbuffer, cutbottom);
|
||||||
|
|
||||||
|
/* If the text in the cutbuffer does end in a newline and the
|
||||||
|
* current cursor position is on the magicline, add a new magicline
|
||||||
|
* for consistency. */
|
||||||
|
if (current == filebot)
|
||||||
|
new_magicline();
|
||||||
|
|
||||||
/* Set the current place we want to where the text from the
|
/* Set the current place we want to where the text from the
|
||||||
* cutbuffer ends. */
|
* cutbuffer ends. */
|
||||||
placewewant = xplustabs();
|
placewewant = xplustabs();
|
||||||
|
|
Loading…
Reference in New Issue