Commit 438f713b authored by Chris Allegretta's avatar Chris Allegretta
Browse files

- nano.c:do_wrap() - Move right increment to part where new line is created,...

- nano.c:do_wrap() - Move right increment to part where new line is created, should change (fix?) some wrapping problems with autoindent


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1004 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
No related merge requests found
Showing with 4 additions and 2 deletions
+4 -2
...@@ -16,6 +16,9 @@ CVS code - ...@@ -16,6 +16,9 @@ CVS code -
do_suspend() do_suspend()
- Call tcsetattr() to restore the old terminal settings, so - Call tcsetattr() to restore the old terminal settings, so
tcsh can use ^C after suspend for example (fixes BUG #68). tcsh can use ^C after suspend for example (fixes BUG #68).
do_wrap()
- Move "right" increment to part where new line is created,
should change (fix?) some wrapping problems with autoindent.
- global.c: - global.c:
shorcut_init() shorcut_init()
- Replace hard coded ALT_G and ALT_H values in the replace - Replace hard coded ALT_G and ALT_H values in the replace
......
...@@ -1031,7 +1031,6 @@ void do_wrap(filestruct * inptr, char input_char) ...@@ -1031,7 +1031,6 @@ void do_wrap(filestruct * inptr, char input_char)
while ((inptr->next->data[i] == ' ' while ((inptr->next->data[i] == ' '
|| inptr->next->data[i] == '\t')) { || inptr->next->data[i] == '\t')) {
i++; i++;
right++;
} }
} }
#endif #endif
...@@ -1102,7 +1101,6 @@ void do_wrap(filestruct * inptr, char input_char) ...@@ -1102,7 +1101,6 @@ void do_wrap(filestruct * inptr, char input_char)
while ((inptr->next->data[i] == ' ' while ((inptr->next->data[i] == ' '
|| inptr->next->data[i] == '\t')) { || inptr->next->data[i] == '\t')) {
i++; i++;
right++;
} }
} }
#endif #endif
...@@ -1223,6 +1221,7 @@ void do_wrap(filestruct * inptr, char input_char) ...@@ -1223,6 +1221,7 @@ void do_wrap(filestruct * inptr, char input_char)
extra++; extra++;
spc++; spc++;
totsize++; totsize++;
right++;
} }
t = charalloc(strlen(temp->data) + extra + 1); t = charalloc(strlen(temp->data) + extra + 1);
strncpy(t, inptr->data, extra); strncpy(t, inptr->data, extra);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment