sort the default strings for brackets and punct, and the "or" atom in

the default regex string for quotestr, in order according to ASCII, and
add minor related documentation updates


git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3256 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
master
David Lawrence Ramsey 2006-01-03 04:53:41 +00:00
parent cb475886b1
commit 5329f23345
5 changed files with 26 additions and 19 deletions

View File

@ -3,6 +3,10 @@ CVS code -
- Miscellaneous comment fixes. (DLR)
- Remove unnecessary #ifdef around termios.h #include in nano.c.
(DLR)
- Sort the default strings for brackets and punct, and the "or"
atom in the default regex string for quotestr, according to
ASCII. Changes to main(), nano.1, nanorc.5, and
nanorc.sample. (DLR)
- winio.c:
edit_scroll()
- Redraw the lines before and after the scrolled region even if
@ -11,6 +15,13 @@ CVS code -
screen down one line and leaves the cursor on the last line of
the screen, in which case we need to update the line after the
scrolled region. (DLR)
- doc/nano.1:
- Better display the default values for quotestr. (DLR)
- doc/nanorc.5:
- Give the default values for the brackets and punct options,
and better display the default values for quotestr. (DLR)
- doc/nanorc.sample:
- Remove unneeded comment. (DLR)
GNU nano 1.3.10 - 2005.12.23
- General:

View File

@ -6,7 +6,7 @@
.\" Public License for copying conditions. There is NO warranty.
.\"
.\" $Id$
.TH NANO 1 "version 1.3.10" "November 21, 2005"
.TH NANO 1 "version 1.3.10" "January 02, 2006"
.\" Please adjust this date whenever revising the manpage.
.\"
@ -84,8 +84,8 @@ Use the blank line below the titlebar as extra editing space.
.TP
.B \-Q \fIstr\fP (\-\-quotestr=\fIstr\fP)
Set the quoting string for justifying. The default is
"^([\ \\t]*[|>:}#])+" if regular expression support is available, or
">\ " otherwise.
"\fI^([\ \\t]*[#:>\\|}])+\fP" if regular expression support is
available, or "\fI>\ \fP" otherwise.
.TP
.B \-R (\-\-restricted)
Restricted mode: Don't read or write to any file not specified on the

View File

@ -6,7 +6,7 @@
.\" Public License for copying conditions. There is NO warranty.
.\"
.\" $Id$
.TH NANORC 5 "version 1.3.10" "November 21, 2005"
.TH NANORC 5 "version 1.3.10" "January 02, 2006"
.\" Please adjust this date whenever revising the manpage.
.\"
.SH NAME
@ -56,7 +56,8 @@ Do backwards searches by default.
.B set brackets "\fIstring\fP"
Set the characters treated as closing brackets. They cannot contain
blank characters. Only closing punctuation, optionally followed by
closing brackets, can end sentences.
closing brackets, can end sentences. The default value is
"\fI"')>]}\fP".
.TP
.B set/unset casesensitive
Do case sensitive searches by default.
@ -113,7 +114,7 @@ Preserve the XON and XOFF keys (^Q and ^S).
.B set punct "\fIstring\fP"
Set the characters treated as closing punctuation. They cannot contain
blank characters. Only closing punctuation, optionally followed by
closing brackets, can end sentences.
closing brackets, can end sentences. The default value is "\fI!.?\fP".
.TP
.B set/unset quickblank
Do quick statusbar blanking. Statusbar messages will disappear after 1
@ -123,11 +124,8 @@ keystroke instead of 25.
The email-quote string, used to justify email-quoted paragraphs. This
is an "extended regular expression" if your system supports them,
otherwise a literal string. The default value is
set quotestr "^([\ \\t]*[|>:}#])+"
if you have regexps, otherwise set quotestr ">\ ". Note that '\\t'
above stands for a literal Tab character.
"\fI^([\ \\t]*[#:>\\|}])+\fP" if you have regexps, or "\fI>\ \fP"
otherwise. Note that '\\t' stands for a literal Tab character.
.TP
.B set/unset rebinddelete
Interpret the Delete key differently so that both Backspace and Delete

View File

@ -24,7 +24,7 @@
## blank characters. Only closing punctuation, optionally followed by
## closing brackets, can end sentences.
##
# set brackets "'")}]>"
# set brackets ""')>]}"
## Do case sensitive searches by default.
# set casesensitive
@ -87,7 +87,7 @@
## blank characters. Only closing punctuation, optionally followed by
## closing brackets, can end sentences.
##
# set punct ".?!"
# set punct "!.?"
## Do quick statusbar blanking. Statusbar messages will disappear after
## 1 keystroke instead of 25. Note that "const" cancels this out.
@ -97,11 +97,9 @@
## The email-quote string, used to justify email-quoted paragraphs.
## This is an extended regular expression if your system supports them,
## otherwise a literal string. Default:
# set quotestr "^([ ]*[\|>:}#])+"
# set quotestr "^([ ]*[#:>\|}])+"
## if you have regexps, otherwise:
# set quotestr "> "
## You can get old nano quoted-justify behavior via:
# set quotestr "(> )+"
## Fix Backspace/Delete confusion problem.
# set rebinddelete

View File

@ -1956,15 +1956,15 @@ int main(int argc, char **argv)
#ifndef DISABLE_JUSTIFY
if (punct == NULL)
punct = mallocstrcpy(NULL, ".?!");
punct = mallocstrcpy(NULL, "!.?");
if (brackets == NULL)
brackets = mallocstrcpy(NULL, "'\")}]>");
brackets = mallocstrcpy(NULL, "\"')>]}");
if (quotestr == NULL)
quotestr = mallocstrcpy(NULL,
#ifdef HAVE_REGEX_H
"^([ \t]*[|>:}#])+"
"^([ \t]*[#:>|}])+"
#else
"> "
#endif