mirror of git://git.sv.gnu.org/nano.git
documentation updates
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1534 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
This commit is contained in:
parent
ec290f2385
commit
aaad3af523
35
ChangeLog
35
ChangeLog
|
@ -24,21 +24,31 @@ CVS code -
|
|||
via Meta-W, and move the line wrapping toggle to Meta-L. New
|
||||
function do_research(). (Wouter van Hemel)
|
||||
- files.c:
|
||||
do_browser():
|
||||
do_browser()
|
||||
- Some of the Pico compatibility options in the file browser
|
||||
that don't work properly for current Pico have been removed.
|
||||
Backspace, 'g', 'l', 'q', and 'u' are invalid, 'd' deletes the
|
||||
highlighted file, and 'r' renames the highlighted file. (DLR)
|
||||
Backspace, 'g', 'l', 'q', and 'u' are invalid. 'd' deletes
|
||||
the highlighted file, and 'r' renames the highlighted file;
|
||||
neither of these are implemented. (DLR)
|
||||
- global.c:
|
||||
toggle_init():
|
||||
toggle_init()
|
||||
- Change the message for the line wrapping toggle from "Auto
|
||||
wrap" to "Auto line wrap", to more clearly associate it with
|
||||
Meta-L. (DLR)
|
||||
shortcut_init()
|
||||
- Change multibuffer-enabled references to opening/closing the
|
||||
previous/next loaded file to switching to/closing the
|
||||
previous/next file buffer, for consistency with other
|
||||
references. (DLR)
|
||||
- nano.c:
|
||||
window_init()
|
||||
- Set keypad() to TRUE regardless of whether PDCurses is being
|
||||
used, as Meta-X apparently turns it off even under ncurses.
|
||||
(DLR)
|
||||
help_init()
|
||||
- Document the support for Esc Esc [character]'s being
|
||||
interpreted as Ctrl-[character], and the support for Pico's
|
||||
Esc Esc [three-digit decimal ASCII code] input method. (DLR)
|
||||
- nano.h:
|
||||
- Define KEY_SUSPEND as -1 when slang is used, as slang has no
|
||||
KEY_SUSPEND equivalent. When nano is compiled with slang
|
||||
|
@ -49,6 +59,23 @@ CVS code -
|
|||
titlebar()
|
||||
- Fix problem with the available space for a filename on the
|
||||
titlebar's being short by one. (DLR)
|
||||
do_credits()
|
||||
- Update the copyright years to "1999-2003", to match those
|
||||
given in the rest of the code. (DLR)
|
||||
- nano.1, nanorc.5, nano.texi:
|
||||
- Change all instances of $SYSCONFDIR to SYSCONFDIR, since
|
||||
SYSCONFDIR is set at compile time and can't be overridden by
|
||||
setting SYSCONFDIR in the environment. (David Benbennick)
|
||||
- Remove -K/--keypad, and document -d/--rebinddelete. (DLR)
|
||||
- Document the support for Esc Esc [character]'s being
|
||||
interpreted as Ctrl-[character], and the support for Pico's
|
||||
Esc Esc [three-digit decimal ASCII code] input method, if
|
||||
applicable. (DLR)
|
||||
- nano.1.html, nanorc.5.html:
|
||||
- Regenerated. (DLR)
|
||||
- nanorc.sample:
|
||||
- Remove duplicate "historylog" entry, remove "keypad" entry,
|
||||
and add "rebinddelete" entry. (DLR)
|
||||
- AUTHORS
|
||||
- Updated to show 1.2/1.3 maintainers.
|
||||
|
||||
|
|
2
files.c
2
files.c
|
@ -1823,7 +1823,7 @@ int do_writeout(const char *path, int exiting, int append)
|
|||
return -1;
|
||||
}
|
||||
#endif
|
||||
if (append == 0 && strcmp(answer, filename) != 0) {
|
||||
if (append == 0 && strcmp(answer, filename)) {
|
||||
struct stat st;
|
||||
|
||||
if (!stat(answer, &st)) {
|
||||
|
|
6
global.c
6
global.c
|
@ -350,7 +350,7 @@ void shortcut_init(int unjustify)
|
|||
nano_help_msg = _("Invoke the help menu");
|
||||
nano_writeout_msg = _("Write the current file to disk");
|
||||
#ifdef ENABLE_MULTIBUFFER
|
||||
nano_exit_msg = _("Close currently loaded file/Exit from nano");
|
||||
nano_exit_msg = _("Close current file buffer/Exit from nano");
|
||||
#else
|
||||
nano_exit_msg = _("Exit from nano");
|
||||
#endif
|
||||
|
@ -400,8 +400,8 @@ void shortcut_init(int unjustify)
|
|||
nano_bracket_msg = _("Find other bracket");
|
||||
#endif
|
||||
#ifdef ENABLE_MULTIBUFFER
|
||||
nano_openprev_msg = _("Open previously loaded file");
|
||||
nano_opennext_msg = _("Open next loaded file");
|
||||
nano_openprev_msg = _("Switch to previous file buffer");
|
||||
nano_opennext_msg = _("Switch to next file buffer");
|
||||
nano_multibuffer_msg = _("Toggle insert into new buffer");
|
||||
#endif
|
||||
#endif /* !DISABLE_HELP */
|
||||
|
|
41
nano.1
41
nano.1
|
@ -3,10 +3,10 @@
|
|||
.\" Chris Allegretta <chrisa@asty.org>
|
||||
.\"
|
||||
.\" This is free documentation, see the latest version of the GNU General
|
||||
.\" Public License for copying conditions. There is NO warranty.
|
||||
.\" Public License for copying conditions. There is NO warranty.
|
||||
.\"
|
||||
.\" $Id$
|
||||
.TH NANO 1 "June 19, 2003"
|
||||
.TH NANO 1 "August 24, 2003"
|
||||
.\" Please adjust this date whenever revising the manpage.
|
||||
.\"
|
||||
|
||||
|
@ -25,7 +25,7 @@ This manual page documents briefly the \fBnano\fP command.
|
|||
.\" \fI<whatever>\fP escape sequences to invoke bold face and italics,
|
||||
.\" respectively.
|
||||
\fBnano\fP is a small, free and friendly editor which aims to replace
|
||||
Pico, the default editor included in the non-free Pine package. Rather
|
||||
Pico, the default editor included in the non-free Pine package. Rather
|
||||
than just copying Pico's look and feel, \fBnano\fP also implements some
|
||||
missing (or disabled by default) features in Pico, such as "search and
|
||||
replace" and "go to line number".
|
||||
|
@ -53,16 +53,11 @@ configured.
|
|||
.TP
|
||||
.B \-I (\-\-ignorercfiles)
|
||||
Don't look at
|
||||
.I $SYSCONFDIR/nanorc
|
||||
.I SYSCONFDIR/nanorc
|
||||
or
|
||||
.IR ~/.nanorc ,
|
||||
if nanorc support is available.
|
||||
.TP
|
||||
.B \-K (\-\-keypad)
|
||||
Do not use the ncurses keypad() call unless necessary. Try this flag if
|
||||
you find that the arrow keys on the numeric keypad do not work for you
|
||||
under nano.
|
||||
.TP
|
||||
.B \-M (\-\-mac)
|
||||
Write file in Mac format.
|
||||
.TP
|
||||
|
@ -79,7 +74,7 @@ Enable regular expression matching for search strings, as well as
|
|||
\\n subexpression replacement for replace strings, if available.
|
||||
.TP
|
||||
.B \-S (\-\-smooth)
|
||||
Enable smooth scrolling. Text will scroll line-by-line, instead of the
|
||||
Enable smooth scrolling. Text will scroll line-by-line, instead of the
|
||||
usual chunk-by-chunk behavior.
|
||||
.TP
|
||||
.B \-T \fInum\fP (\-\-tabsize=\fInum\fP)
|
||||
|
@ -96,11 +91,16 @@ to use, if available.
|
|||
.B \-c (\-\-const)
|
||||
Constantly show the cursor position.
|
||||
.TP
|
||||
.B \-d (\-\-rebinddelete)
|
||||
Interpret the Delete key differently so that both Backspace and Delete
|
||||
work properly. You should only need to use this option if Backspace
|
||||
acts like Delete on your system.
|
||||
.TP
|
||||
.B \-h (\-\-help)
|
||||
Display a summary of command line options.
|
||||
.TP
|
||||
.B \-i (\-\-autoindent)
|
||||
Indent new lines to the previous line's indentation. Useful when editing
|
||||
Indent new lines to the previous line's indentation. Useful when editing
|
||||
source code.
|
||||
.TP
|
||||
.B \-k (\-\-cut)
|
||||
|
@ -116,12 +116,12 @@ perhaps?
|
|||
Enable mouse support (if available for your system).
|
||||
.TP
|
||||
.B \-o \fIdir\fP (\-\-operatingdir=\fIdir\fP)
|
||||
Set operating directory. Makes nano set up something similar to a
|
||||
Set operating directory. Makes nano set up something similar to a
|
||||
chroot.
|
||||
.TP
|
||||
.B \-p (\-\-preserve)
|
||||
Preserve the XON and XOFF sequences (^Q and ^S) so they will be
|
||||
caught by the terminal.
|
||||
Preserve the XON and XOFF sequences (^Q and ^S) so they will be caught
|
||||
by the terminal.
|
||||
.TP
|
||||
.B \-r \fIcols\fP (\-\-fill=\fIcols\fP)
|
||||
Wrap lines at column \fIcols\fP. By default, this is the width of the
|
||||
|
@ -151,9 +151,8 @@ Enable suspend ability.
|
|||
Ignored, for compatibility with Pico.
|
||||
|
||||
.SH INITIALIZATION FILE
|
||||
\fBnano\fP will read initialization files in the following
|
||||
order:
|
||||
.IR $SYSCONFDIR/nanorc ,
|
||||
\fBnano\fP will read initialization files in the following order:
|
||||
.IR SYSCONFDIR/nanorc ,
|
||||
then
|
||||
.IR ~/.nanorc .
|
||||
Please see
|
||||
|
@ -168,9 +167,9 @@ SIGTERM or runs out of memory, when it will write the buffer into a file
|
|||
named
|
||||
.I nano.save
|
||||
if the buffer didn't have a name already, or will add a ".save" suffix
|
||||
to the current filename. If an emergency file with that name already
|
||||
to the current filename. If an emergency file with that name already
|
||||
exists in the current directory, ".save" and a number (e.g. ".save.1")
|
||||
will be suffixed to the current filename in order to make it unique. In
|
||||
will be suffixed to the current filename in order to make it unique. In
|
||||
multibuffer mode, \fBnano\fP will write all the open buffers to the
|
||||
respective emergency files.
|
||||
|
||||
|
@ -201,5 +200,5 @@ Chris Allegretta <chrisa@asty.org>, et al (see
|
|||
and
|
||||
.I THANKS
|
||||
for details). This manual page was originally written by Jordi Mallach
|
||||
<jordi@sindominio.net>, for the Debian GNU system (but may be
|
||||
used by others).
|
||||
<jordi@sindominio.net>, for the Debian GNU system (but may be used by
|
||||
others).
|
||||
|
|
43
nano.1.html
43
nano.1.html
|
@ -1,7 +1,7 @@
|
|||
<HTML><HEAD><TITLE>Manpage of NANO</TITLE>
|
||||
</HEAD><BODY>
|
||||
<H1>NANO</H1>
|
||||
Section: User Commands (1)<BR>Updated: June 19, 2003<BR><A HREF="#index">Index</A>
|
||||
Section: User Commands (1)<BR>Updated: August 24, 2003<BR><A HREF="#index">Index</A>
|
||||
<A HREF="http://localhost/cgi-bin/man/man2html">Return to Main Contents</A><HR>
|
||||
|
||||
|
||||
|
@ -32,7 +32,7 @@ This manual page documents briefly the <B>nano</B> command.
|
|||
|
||||
|
||||
<B>nano</B> is a small, free and friendly editor which aims to replace
|
||||
Pico, the default editor included in the non-free Pine package. Rather
|
||||
Pico, the default editor included in the non-free Pine package. Rather
|
||||
than just copying Pico's look and feel, <B>nano</B> also implements some
|
||||
missing (or disabled by default) features in Pico, such as "search and
|
||||
replace" and "go to line number".
|
||||
|
@ -70,18 +70,12 @@ configured.
|
|||
|
||||
<DD>
|
||||
Don't look at
|
||||
<I>$SYSCONFDIR/nanorc</I>
|
||||
<I>SYSCONFDIR/nanorc</I>
|
||||
|
||||
or
|
||||
<I>~/.nanorc</I>,
|
||||
|
||||
if nanorc support is available.
|
||||
<DT><B>-K (--keypad)</B>
|
||||
|
||||
<DD>
|
||||
Do not use the ncurses keypad() call unless necessary. Try this flag if
|
||||
you find that the arrow keys on the numeric keypad do not work for you
|
||||
under nano.
|
||||
<DT><B>-M (--mac)</B>
|
||||
|
||||
<DD>
|
||||
|
@ -104,7 +98,7 @@ Enable regular expression matching for search strings, as well as
|
|||
<DT><B>-S (--smooth)</B>
|
||||
|
||||
<DD>
|
||||
Enable smooth scrolling. Text will scroll line-by-line, instead of the
|
||||
Enable smooth scrolling. Text will scroll line-by-line, instead of the
|
||||
usual chunk-by-chunk behavior.
|
||||
<DT><B>-T </B><I>num</I> (--tabsize=<I>num</I>)
|
||||
|
||||
|
@ -125,6 +119,12 @@ to use, if available.
|
|||
|
||||
<DD>
|
||||
Constantly show the cursor position.
|
||||
<DT><B>-d (--rebinddelete)</B>
|
||||
|
||||
<DD>
|
||||
Interpret the Delete key differently so that both Backspace and Delete
|
||||
work properly. You should only need to use this option if Backspace
|
||||
acts like Delete on your system.
|
||||
<DT><B>-h (--help)</B>
|
||||
|
||||
<DD>
|
||||
|
@ -132,7 +132,7 @@ Display a summary of command line options.
|
|||
<DT><B>-i (--autoindent)</B>
|
||||
|
||||
<DD>
|
||||
Indent new lines to the previous line's indentation. Useful when editing
|
||||
Indent new lines to the previous line's indentation. Useful when editing
|
||||
source code.
|
||||
<DT><B>-k (--cut)</B>
|
||||
|
||||
|
@ -153,13 +153,13 @@ Enable mouse support (if available for your system).
|
|||
<DT><B>-o </B><I>dir</I> (--operatingdir=<I>dir</I>)
|
||||
|
||||
<DD>
|
||||
Set operating directory. Makes nano set up something similar to a
|
||||
Set operating directory. Makes nano set up something similar to a
|
||||
chroot.
|
||||
<DT><B>-p (--preserve)</B>
|
||||
|
||||
<DD>
|
||||
Preserve the XON and XOFF sequences (^Q and ^S) so they will be
|
||||
caught by the terminal.
|
||||
Preserve the XON and XOFF sequences (^Q and ^S) so they will be caught
|
||||
by the terminal.
|
||||
<DT><B>-r </B><I>cols</I> (--fill=<I>cols</I>)
|
||||
|
||||
<DD>
|
||||
|
@ -200,9 +200,8 @@ Ignored, for compatibility with Pico.
|
|||
<A NAME="lbAF"> </A>
|
||||
<H2>INITIALIZATION FILE</H2>
|
||||
|
||||
<B>nano</B> will read initialization files in the following
|
||||
order:
|
||||
<I>$SYSCONFDIR/nanorc</I>,
|
||||
<B>nano</B> will read initialization files in the following order:
|
||||
<I>SYSCONFDIR/nanorc</I>,
|
||||
|
||||
then
|
||||
<I>~/.nanorc</I>.
|
||||
|
@ -223,9 +222,9 @@ named
|
|||
<I>nano.save</I>
|
||||
|
||||
if the buffer didn't have a name already, or will add a ".save" suffix
|
||||
to the current filename. If an emergency file with that name already
|
||||
to the current filename. If an emergency file with that name already
|
||||
exists in the current directory, ".save" and a number (e.g. ".save.1")
|
||||
will be suffixed to the current filename in order to make it unique. In
|
||||
will be suffixed to the current filename in order to make it unique. In
|
||||
multibuffer mode, <B>nano</B> will write all the open buffers to the
|
||||
respective emergency files.
|
||||
<P>
|
||||
|
@ -271,8 +270,8 @@ and
|
|||
<I>THANKS</I>
|
||||
|
||||
for details). This manual page was originally written by Jordi Mallach
|
||||
<<A HREF="mailto:jordi@sindominio.net">jordi@sindominio.net</A>>, for the Debian GNU system (but may be
|
||||
used by others).
|
||||
<<A HREF="mailto:jordi@sindominio.net">jordi@sindominio.net</A>>, for the Debian GNU system (but may be used by
|
||||
others).
|
||||
<P>
|
||||
|
||||
<HR>
|
||||
|
@ -293,6 +292,6 @@ used by others).
|
|||
This document was created by
|
||||
<A HREF="http://localhost/cgi-bin/man/man2html">man2html</A>,
|
||||
using the manual pages.<BR>
|
||||
Time: 22:27:55 GMT, June 19, 2003
|
||||
Time: 21:16:54 GMT, August 24, 2003
|
||||
</BODY>
|
||||
</HTML>
|
||||
|
|
19
nano.c
19
nano.c
|
@ -358,12 +358,15 @@ void help_init(void)
|
|||
"The bottom two lines show the most commonly used shortcuts "
|
||||
"in the editor.\n\n "
|
||||
"The notation for shortcuts is as follows: Control-key "
|
||||
"sequences are notated with a caret (^) symbol and are entered "
|
||||
"with the Control (Ctrl) key. Escape-key sequences are notated "
|
||||
"with the Meta (M) symbol and can be entered using either the "
|
||||
"Esc, Alt or Meta key depending on your keyboard setup. The "
|
||||
"following keystrokes are available in the main editor window. "
|
||||
"Alternative keys are shown in parentheses:\n\n");
|
||||
"sequences are notated with a caret (^) symbol and can be "
|
||||
"entered either by using the Control (Ctrl) key or pressing the "
|
||||
"Esc key twice. Escape-key sequences are notated with the Meta "
|
||||
"(M) symbol and can be entered using either the Esc, Alt or "
|
||||
"Meta key depending on your keyboard setup. Also, pressing Esc "
|
||||
"twice and then typing a three-digit number from 000 to 255 "
|
||||
"will enter the character with the corresponding ASCII code. "
|
||||
"The following keystrokes are available in the main editor "
|
||||
"window. Alternative keys are shown in parentheses:\n\n");
|
||||
|
||||
allocsize += strlen(ptr);
|
||||
|
||||
|
@ -1570,8 +1573,8 @@ int do_wrap(filestruct *inptr)
|
|||
#endif /* !DISABLE_WRAPPING */
|
||||
|
||||
#ifndef DISABLE_SPELLER
|
||||
/* word is misspelled in the file. Let the user replace it. We return
|
||||
False if the user cancels. */
|
||||
/* A word is misspelled in the file. Let the user replace it. We
|
||||
* return False if the user cancels. */
|
||||
int do_int_spell_fix(const char *word)
|
||||
{
|
||||
char *save_search;
|
||||
|
|
126
nano.texi
126
nano.texi
|
@ -9,7 +9,7 @@
|
|||
@smallbook
|
||||
@set EDITION 0.1
|
||||
@set VERSION 1.2.2
|
||||
@set UPDATED 17 Jan 2003
|
||||
@set UPDATED 24 Aug 2003
|
||||
|
||||
@dircategory Editors
|
||||
@direntry
|
||||
|
@ -95,8 +95,8 @@ internationalization support, and filename tab completion.
|
|||
|
||||
The original goal for @code{nano} was a complete bug-for-bug compatible
|
||||
emulation of Pico, but nano's main goal is to be as compatible as
|
||||
possible while offering a superset of Pico's functionality.
|
||||
Also see @xref{Pico Compatibility}, for other differences.
|
||||
possible while offering a superset of Pico's functionality. Also see
|
||||
@xref{Pico Compatibility}, for other differences.
|
||||
|
||||
Email bug reports to @email{nano@@nano-editor.org}.
|
||||
|
||||
|
@ -118,14 +118,9 @@ Write file in DOS format.
|
|||
Enable multiple file buffers, if available.
|
||||
|
||||
@item -I, --ignorercfiles
|
||||
Don't look at $SYSCONFDIR/nanorc or ~/.nanorc, if nanorc support is
|
||||
Don't look at SYSCONFDIR/nanorc or ~/.nanorc, if nanorc support is
|
||||
available.
|
||||
|
||||
@item -K, --keypad
|
||||
Do not use the ncurses keypad() call unless necessary. Try this flag if
|
||||
you find that the arrow keys on the numeric keypad do not work for you
|
||||
under @code{nano}.
|
||||
|
||||
@item -M, --mac
|
||||
Write file in Mac format.
|
||||
|
||||
|
@ -161,6 +156,11 @@ available.
|
|||
@item -c, --const
|
||||
Constantly display the cursor position and line number on the statusbar.
|
||||
|
||||
@item -d, --rebinddelete
|
||||
Interpret the Delete key differently so that both Backspace and Delete
|
||||
work properly. You should only need to use this option if Backspace
|
||||
acts like Delete on your system.
|
||||
|
||||
@item -h, --help
|
||||
Print the usage and exit.
|
||||
|
||||
|
@ -181,18 +181,18 @@ Enables the use of the mouse to select text (currently only useful for
|
|||
running under the X window system).
|
||||
|
||||
@item -o [dir], --operatingdir=[dir]
|
||||
Set operating directory. Makes @code{nano} set up something similar to a
|
||||
chroot.
|
||||
Set operating directory. Makes @code{nano} set up something similar to
|
||||
a chroot.
|
||||
|
||||
@item -p, --preserve
|
||||
Preserve the ^Q (XON) and ^S (XOFF) sequences so data being sent to the editor
|
||||
can be can be stopped and started.
|
||||
Preserve the ^Q (XON) and ^S (XOFF) sequences so data being sent to the
|
||||
editor can be can be stopped and started.
|
||||
|
||||
@item -r [#cols], --fill=[#cols].
|
||||
Wrap lines at column #cols. By default this is the width of the screen,
|
||||
less eight. If this value is negative, wrapping will occur at #cols from
|
||||
the right of the screen, allowing it to vary along with the screen width
|
||||
if the screen is resized.
|
||||
less eight. If this value is negative, wrapping will occur at #cols
|
||||
from the right of the screen, allowing it to vary along with the screen
|
||||
width if the screen is resized.
|
||||
|
||||
@item -s [prog], --speller=[prog]
|
||||
Invoke [prog] as the spell checker. By default, @code{nano} uses its
|
||||
|
@ -207,20 +207,20 @@ composer of a mailer program.
|
|||
@anchor{Expert Mode}
|
||||
@item -x, --nohelp
|
||||
In Expert Mode, the Shortcut Lists will not appear at the bottom of the
|
||||
screen. This affects the location of the statusbar as well, as in Expert
|
||||
Mode it is located at the very bottom of the editor.
|
||||
screen. This affects the location of the statusbar as well, as in
|
||||
Expert Mode it is located at the very bottom of the editor.
|
||||
|
||||
Note: When accessing the help system, Expert Mode is temporarily disabled
|
||||
to display the help system navigation keys.
|
||||
Note: When accessing the help system, Expert Mode is temporarily
|
||||
disabled to display the help system navigation keys.
|
||||
|
||||
@item -v, --view
|
||||
Do not allow the contents of the file to be altered. Note that this
|
||||
flag should NOT be used in place of correct file permissions to implement
|
||||
a read-only file.
|
||||
flag should NOT be used in place of correct file permissions to
|
||||
implement a read-only file.
|
||||
|
||||
@item -w, --nowrap
|
||||
Do not wrap long lines at any length. This option overrides any value for
|
||||
-r.
|
||||
Do not wrap long lines at any length. This option overrides any value
|
||||
for -r.
|
||||
|
||||
@item -z, --suspend
|
||||
Enable suspend ability of @code{nano} using the system's suspend
|
||||
|
@ -255,32 +255,35 @@ edited.
|
|||
@section Special Functions
|
||||
|
||||
Special functions use the Control key (displayed in the help and
|
||||
shortcut lists as ^) or the Meta key (displayed as M).
|
||||
shortcut lists as ^), the Meta key (displayed as M), or the Esc key.
|
||||
|
||||
@itemize @bullet
|
||||
|
||||
@item
|
||||
Control key sequences are entered by holding down the Control key and
|
||||
pressing the desired letter.
|
||||
pressing the desired key, or by pressing the Esc key twice and pressing
|
||||
the desired key.
|
||||
@item
|
||||
Meta key sequences can be entered in a number of
|
||||
possible ways: Pressing the Escape key, then releasing it and pressing
|
||||
the desired key, or holding down the Alt key while pressing the desired
|
||||
key. This varies from keyboard to keyboard, and certain commercial
|
||||
operating systems ``swallow'' the Alt key so that it never reaches the
|
||||
application. If your operating system does this, you should use the
|
||||
Escape key to generate Meta key sequences.
|
||||
Pressing Esc twice and then typing a three-digit number from 000 to 255
|
||||
will enter the character with the corresponding ASCII code.
|
||||
@item
|
||||
Meta key sequences can be entered in a number of possible ways: Pressing
|
||||
the Escape key, then releasing it and pressing the desired key, or
|
||||
holding down the Alt key while pressing the desired key. This varies
|
||||
from keyboard to keyboard, and certain commercial operating systems
|
||||
``swallow'' the Alt key so that it never reaches the application. If
|
||||
your operating system does this, you should use the Escape key to
|
||||
generate Meta key sequences.
|
||||
@end itemize
|
||||
|
||||
@node The Titlebar, The Statusbar, Special Functions, Editor Basics
|
||||
@section The Titlebar
|
||||
|
||||
The titlebar is the line displayed at the top of the editor. There are
|
||||
three sections: left, center and right. The section on the left displays
|
||||
the version of @code{nano} being used. The center section displays the
|
||||
current file name, or ``New Buffer'' if the file has not yet been named.
|
||||
The section on the right will display ``Modified'' if the file has been
|
||||
modified since it was last saved or opened.
|
||||
three sections: left, center and right. The section on the left
|
||||
displays the version of @code{nano} being used. The center section
|
||||
displays the current file name, or ``New Buffer'' if the file has not
|
||||
yet been named. The section on the right will display ``Modified'' if
|
||||
the file has been modified since it was last saved or opened.
|
||||
|
||||
Special modes: When @code{nano} is in ``File browser'' mode, the center
|
||||
section will display the current directory instead of the filename.
|
||||
|
@ -317,8 +320,8 @@ and ^V (Page Down) keys. ^X exits the help system.
|
|||
@chapter Feature Toggles
|
||||
|
||||
Toggles allow you to change certain aspects of the editor that
|
||||
would normally be done via command line flags. They are invoked via
|
||||
certain Meta key sequences. @xref{Special Functions}, for more info.
|
||||
would normally be done via command line flags. They are invoked via
|
||||
certain Meta key sequences. @xref{Special Functions}, for more info.
|
||||
The following global toggles are available:
|
||||
|
||||
@table @code
|
||||
|
@ -388,15 +391,15 @@ are certain differences between the editors:
|
|||
@table @code
|
||||
@item Search and Replace History
|
||||
As of version 1.2.2 of @code{nano}, text entered as search or replace
|
||||
strings will be stored and can be accessed with the up/down
|
||||
arrow keys. Previously, @code{nano} offered a more consistent, but incompatible
|
||||
with Pico, method for entering search and replace strings. In the old
|
||||
strings will be stored and can be accessed with the up/down arrow keys.
|
||||
Previously, @code{nano} offered a more consistent, but incompatible with
|
||||
Pico, method for entering search and replace strings. In the old
|
||||
method, previous entries would be displayed by default as editable text
|
||||
in front of the cursor, as opposed to being bracketed and uneditable as
|
||||
it is in Pico. The old behavior could be made compatible with Pico via the
|
||||
@code{-p} flag, but recent versions of Pico use the @code{-p} flag
|
||||
to preserve the XON and XOFF sequences within the editor. Since with the new
|
||||
method search and replace strings can still be edited by simply
|
||||
it is in Pico. The old behavior could be made compatible with Pico via
|
||||
the @code{-p} flag, but recent versions of Pico use the @code{-p} flag
|
||||
to preserve the XON and XOFF sequences within the editor. Since with
|
||||
the new method search and replace strings can still be edited by simply
|
||||
hitting the up arrow key once, the old method was removed completely.
|
||||
|
||||
|
||||
|
@ -407,11 +410,10 @@ appended to a new or existing file using the Writeout key (^O).
|
|||
@item Toggles
|
||||
Many options which alter the functionality of the program can be
|
||||
"toggled" on or off using Meta key sequences, meaning the program does
|
||||
not have to be restarted to turn a particular feature of the editor
|
||||
on or off. Please see the internal help function (^G) for a list of
|
||||
what functions can be toggled for a particular version of
|
||||
@code{nano}. Also see @xref{Feature Toggles}, though this may be out
|
||||
of date.
|
||||
not have to be restarted to turn a particular feature of the editor on
|
||||
or off. Please see the internal help function (^G) for a list of what
|
||||
functions can be toggled for a particular version of @code{nano}. Also
|
||||
see @xref{Feature Toggles}, though this may be out of date.
|
||||
|
||||
@item Cursor Position Display
|
||||
The output of the "Display Cursor Position" in @code{nano} displays
|
||||
|
@ -420,21 +422,21 @@ position of the cursor.
|
|||
|
||||
@item Interactive Replace and Spell Checker
|
||||
It is worth noting that the @code{nano} replace function is interactive,
|
||||
i.e. it does not stop after one search string is found and automatically
|
||||
i.e, it does not stop after one search string is found and automatically
|
||||
replace it. The @code{nano} implementation will stop at each search
|
||||
string found and query whether to replace this instance or not. The
|
||||
internal spell checker operates similarly. Note that these is no way
|
||||
to force these functions to behave in the Pico fashion. As of
|
||||
version 1.2.2, misspelled words are sorted and trimmed for
|
||||
uniqueness in the internal spell checker such that the words 'apple'
|
||||
and 'Apple' will be prompted for correction separately.
|
||||
internal spell checker operates similarly. Note that these is no way to
|
||||
force these functions to behave in the Pico fashion. As of version
|
||||
1.2.2, misspelled words are sorted and trimmed for uniqueness in the
|
||||
internal spell checker such that the words 'apple' and 'Apple' will be
|
||||
prompted for correction separately.
|
||||
@end table
|
||||
|
||||
@node Building and Configure Options, , Pico Compatibility, Top
|
||||
@chapter Building and Configure Options
|
||||
|
||||
Building @code{nano} from source is fairly straightforward if you are familiar
|
||||
with compiling programs with autoconf support:
|
||||
Building @code{nano} from source is fairly straightforward if you are
|
||||
familiar with compiling programs with autoconf support:
|
||||
|
||||
@itemize @bullet
|
||||
@item tar xvfz nano-x.y.z.tar.gz (where x.y.z is the version of nano)
|
||||
|
@ -486,7 +488,7 @@ Disable all word wrapping in the editor. This also eliminates the -w
|
|||
command line flag, as nonwrapping is then the default behavior.
|
||||
|
||||
@item --disable-nls
|
||||
Disables Native Language support. This will make the available GNU
|
||||
Disables Native Language support. This will make the available GNU
|
||||
@code{nano} translations unusable.
|
||||
|
||||
@item --with-slang
|
||||
|
|
63
nanorc.5
63
nanorc.5
|
@ -2,10 +2,10 @@
|
|||
.\" nanorc.5 is Copyright (C) 2003 Free Software Foundation, Inc.
|
||||
.\"
|
||||
.\" This is free documentation, see the latest version of the GNU General
|
||||
.\" Public License for copying conditions. There is NO warranty.
|
||||
.\" Public License for copying conditions. There is NO warranty.
|
||||
.\"
|
||||
.\" $Id$
|
||||
.TH NANORC 5 "June 19, 2003"
|
||||
.TH NANORC 5 "August 24, 2003"
|
||||
.\" Please adjust this date whenever revising the manpage.
|
||||
.\"
|
||||
.SH NAME
|
||||
|
@ -14,26 +14,26 @@ nanorc \- GNU nano's rcfile
|
|||
This manual page documents GNU \fBnano\fP's rcfile.
|
||||
.PP
|
||||
\fBnano\fP is a small, free and friendly editor which aims to replace
|
||||
Pico, the default editor included in the non-free Pine package. Rather
|
||||
Pico, the default editor included in the non-free Pine package. Rather
|
||||
than just copying Pico's look and feel, \fBnano\fP also implements some
|
||||
missing (or disabled by default) features in Pico, such as "search and
|
||||
replace" and "go to line number".
|
||||
.PP
|
||||
The \fInanorc\fP file contains the default settings for \fBnano\fP.
|
||||
During startup, \fBnano\fP will first read its system-wide settings from
|
||||
.IR $SYSCONFDIR/nanorc ,
|
||||
.IR SYSCONFDIR/nanorc ,
|
||||
and then user-specific settings from
|
||||
.IR ~/.nanorc .
|
||||
|
||||
.SH OPTIONS
|
||||
The configuration file accepts a series of "set" and "unset" commands,
|
||||
which can be used to configure nano on startup without using the
|
||||
command-line options. Additionally, the "syntax" and "color" keywords
|
||||
are used to define syntax highlighting rules for different text patterns.
|
||||
GNU nano will read one command per line.
|
||||
command-line options. Additionally, the "syntax" and "color" keywords
|
||||
are used to define syntax highlighting rules for different text
|
||||
patterns. GNU nano will read one command per line.
|
||||
|
||||
Options in rcfiles take precedence over nano's defaults, and command line
|
||||
options override rcfile settings.
|
||||
Options in rcfiles take precedence over nano's defaults, and command
|
||||
line options override rcfile settings.
|
||||
|
||||
Options are unset by default, except for options that take an argument.
|
||||
|
||||
|
@ -62,9 +62,6 @@ Enable
|
|||
.I ~/.nano_history
|
||||
for saving and reading search/replace strings.
|
||||
.TP
|
||||
\fBset/unset keypad\fP
|
||||
Use alternate keypad routines.
|
||||
.TP
|
||||
\fBset/unset multibuffer\fP
|
||||
Allow inserting files into their own buffers.
|
||||
.TP
|
||||
|
@ -82,23 +79,28 @@ Don't wrap text at all.
|
|||
.TP
|
||||
\fBset operatingdir "\fIdirectory\fP"\fP
|
||||
\fBnano\fP will only read and write files inside \fIdirectory\fP and its
|
||||
subdirectories. Also, the current directory is changed to here, so files
|
||||
are inserted from this dir. By default the operating directory feature is
|
||||
turned off.
|
||||
subdirectories. Also, the current directory is changed to here, so
|
||||
files are inserted from this dir. By default the operating directory
|
||||
feature is turned off.
|
||||
.TP
|
||||
\fBset/unset preserve\fP
|
||||
Preserve the XON and XOFF keys (^Q and ^S).
|
||||
.TP
|
||||
\fBset quotestr "\fIstring\fP"\fP
|
||||
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
|
||||
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.
|
||||
.TP
|
||||
\fBset/unset rebinddelete\fP
|
||||
Interpret the Delete key differently so that both Backspace and Delete
|
||||
work properly. You should only need to use this option if Backspace
|
||||
acts like Delete on your system.
|
||||
.TP
|
||||
\fBset/unset regexp\fP
|
||||
Do regular expression searches by default.
|
||||
.TP
|
||||
|
@ -123,32 +125,31 @@ Save automatically on exit, don't prompt.
|
|||
Disallow file modification.
|
||||
.TP
|
||||
.B syntax "\fIstr\fP" ["\fIfileregex\fP" ... ]
|
||||
Defines a syntax named \fIstr\fP which can be activated via the
|
||||
\fB-Y\fP flag, or will be automatically activated if the current
|
||||
filename matches \fIfileregex\fP. All following \fBcolor\fP statements
|
||||
will apply to \fIsyntax\fP until a new syntax is defined.
|
||||
Defines a syntax named \fIstr\fP which can be activated via the \fB-Y\fP
|
||||
flag, or will be automatically activated if the current filename matches
|
||||
\fIfileregex\fP. All following \fBcolor\fP statements will apply to
|
||||
\fIsyntax\fP until a new syntax is defined.
|
||||
.TP
|
||||
.B color \fIfgcolor\fP[,\fIbgcolor\fP] "\fIregex\fP" ...
|
||||
For the currently defined syntax, display all expressions matching
|
||||
\fIregex\fP with foreground color \fIfgcolor\fP and optional background
|
||||
color \fIbgcolor\fP. Legal colors for foreground and background color are:
|
||||
white, black, red, blue, green, yellow, magenta, and cyan. You may use
|
||||
the prefix "bright" to force a stronger color highlight. If your
|
||||
color \fIbgcolor\fP. Legal colors for foreground and background color
|
||||
are: white, black, red, blue, green, yellow, magenta, and cyan. You may
|
||||
use the prefix "bright" to force a stronger color highlight. If your
|
||||
terminal supports transparency, not specifying a \fIbgcolor\fP tells
|
||||
\fBnano\fP to attempt to use a transparent background.
|
||||
.TP
|
||||
.B color \fIfgcolor\fP[,\fIbgcolor\fP] start="\fIsr\fP" end="\fIer\fP"
|
||||
Display expressions which start with \fIsr\fP and end with \fIer\fP
|
||||
with foreground color \fIfgcolor\fP and optional
|
||||
background color \fIbgcolor\fP. This allows syntax highlighting to span
|
||||
multiple lines. Note that all subsequent instances of \fIsr\fP after
|
||||
an initial \fIsr\fP is found will be highlighted until the first
|
||||
instance of \fIer\fP.
|
||||
with foreground color \fIfgcolor\fP and optional background color
|
||||
\fIbgcolor\fP. This allows syntax highlighting to span multiple lines.
|
||||
Note that all subsequent instances of \fIsr\fP after an initial \fIsr\fP
|
||||
is found will be highlighted until the first instance of \fIer\fP.
|
||||
\fI
|
||||
|
||||
.SH FILES
|
||||
.TP
|
||||
.I $SYSCONFDIR/nanorc
|
||||
.I SYSCONFDIR/nanorc
|
||||
System-wide configuration file
|
||||
.TP
|
||||
.I ~/.nanorc
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<HTML><HEAD><TITLE>Manpage of NANORC</TITLE>
|
||||
</HEAD><BODY>
|
||||
<H1>NANORC</H1>
|
||||
Section: File Formats (5)<BR>Updated: June 19, 2003<BR><A HREF="#index">Index</A>
|
||||
Section: File Formats (5)<BR>Updated: August 24, 2003<BR><A HREF="#index">Index</A>
|
||||
<A HREF="http://localhost/cgi-bin/man/man2html">Return to Main Contents</A><HR>
|
||||
|
||||
|
||||
|
@ -17,7 +17,7 @@ This manual page documents GNU <B>nano</B>'s rcfile.
|
|||
<P>
|
||||
|
||||
<B>nano</B> is a small, free and friendly editor which aims to replace
|
||||
Pico, the default editor included in the non-free Pine package. Rather
|
||||
Pico, the default editor included in the non-free Pine package. Rather
|
||||
than just copying Pico's look and feel, <B>nano</B> also implements some
|
||||
missing (or disabled by default) features in Pico, such as "search and
|
||||
replace" and "go to line number".
|
||||
|
@ -25,7 +25,7 @@ replace" and "go to line number".
|
|||
|
||||
The <I>nanorc</I> file contains the default settings for <B>nano</B>.
|
||||
During startup, <B>nano</B> will first read its system-wide settings from
|
||||
<I>$SYSCONFDIR/nanorc</I>,
|
||||
<I>SYSCONFDIR/nanorc</I>,
|
||||
|
||||
and then user-specific settings from
|
||||
<I>~/.nanorc</I>.
|
||||
|
@ -36,12 +36,12 @@ and then user-specific settings from
|
|||
|
||||
The configuration file accepts a series of "set" and "unset" commands,
|
||||
which can be used to configure nano on startup without using the
|
||||
command-line options. Additionally, the "syntax" and "color" keywords
|
||||
are used to define syntax highlighting rules for different text patterns.
|
||||
GNU nano will read one command per line.
|
||||
command-line options. Additionally, the "syntax" and "color" keywords
|
||||
are used to define syntax highlighting rules for different text
|
||||
patterns. GNU nano will read one command per line.
|
||||
<P>
|
||||
Options in rcfiles take precedence over nano's defaults, and command line
|
||||
options override rcfile settings.
|
||||
Options in rcfiles take precedence over nano's defaults, and command
|
||||
line options override rcfile settings.
|
||||
<P>
|
||||
Options are unset by default, except for options that take an argument.
|
||||
<P>
|
||||
|
@ -66,8 +66,6 @@ Enable
|
|||
<I>~/.nano_history</I>
|
||||
|
||||
for saving and reading search/replace strings.
|
||||
<DT><B>set/unset keypad</B><DD>
|
||||
Use alternate keypad routines.
|
||||
<DT><B>set/unset multibuffer</B><DD>
|
||||
Allow inserting files into their own buffers.
|
||||
<DT><B>set/unset noconvert</B><DD>
|
||||
|
@ -80,20 +78,24 @@ Don't display the help lists at the bottom of the screen.
|
|||
Don't wrap text at all.
|
||||
<DT><B>set operatingdir "</B><I>directory</I>"<DD>
|
||||
<B>nano</B> will only read and write files inside <I>directory</I> and its
|
||||
subdirectories. Also, the current directory is changed to here, so files
|
||||
are inserted from this dir. By default the operating directory feature is
|
||||
turned off.
|
||||
subdirectories. Also, the current directory is changed to here, so
|
||||
files are inserted from this dir. By default the operating directory
|
||||
feature is turned off.
|
||||
<DT><B>set/unset preserve</B><DD>
|
||||
Preserve the XON and XOFF keys (^Q and ^S).
|
||||
<DT><B>set quotestr "</B><I>string</I>"<DD>
|
||||
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
|
||||
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
|
||||
<P>
|
||||
<TT> </TT>set quotestr "^([ \t]*[|>:}#])+"<BR>
|
||||
<P>
|
||||
if you have regexps, otherwise set quotestr "> ". Note that '\t'
|
||||
above stands for a literal Tab character.
|
||||
<DT><B>set/unset rebinddelete</B><DD>
|
||||
Interpret the Delete key differently so that both Backspace and Delete
|
||||
work properly. You should only need to use this option if Backspace
|
||||
acts like Delete on your system.
|
||||
<DT><B>set/unset regexp</B><DD>
|
||||
Do regular expression searches by default.
|
||||
<DT><B>set/unset smooth</B><DD>
|
||||
|
@ -113,29 +115,28 @@ Disallow file modification.
|
|||
<DT><B>syntax </B><I>str</I> [<I>fileregex</I> ... ]
|
||||
|
||||
<DD>
|
||||
Defines a syntax named <I>str</I> which can be activated via the
|
||||
<B>-Y</B> flag, or will be automatically activated if the current
|
||||
filename matches <I>fileregex</I>. All following <B>color</B> statements
|
||||
will apply to <I>syntax</I> until a new syntax is defined.
|
||||
Defines a syntax named <I>str</I> which can be activated via the <B>-Y</B>
|
||||
flag, or will be automatically activated if the current filename matches
|
||||
<I>fileregex</I>. All following <B>color</B> statements will apply to
|
||||
<I>syntax</I> until a new syntax is defined.
|
||||
<DT><B>color </B><I>fgcolor</I>[,<I>bgcolor</I>] <I>regex</I> ...
|
||||
|
||||
<DD>
|
||||
For the currently defined syntax, display all expressions matching
|
||||
<I>regex</I> with foreground color <I>fgcolor</I> and optional background
|
||||
color <I>bgcolor</I>. Legal colors for foreground and background color are:
|
||||
white, black, red, blue, green, yellow, magenta, and cyan. You may use
|
||||
the prefix "bright" to force a stronger color highlight. If your
|
||||
color <I>bgcolor</I>. Legal colors for foreground and background color
|
||||
are: white, black, red, blue, green, yellow, magenta, and cyan. You may
|
||||
use the prefix "bright" to force a stronger color highlight. If your
|
||||
terminal supports transparency, not specifying a <I>bgcolor</I> tells
|
||||
<B>nano</B> to attempt to use a transparent background.
|
||||
<DT><B>color </B><I>fgcolor</I>[,<I>bgcolor</I>] start=<I>sr</I> end=<I>er</I>
|
||||
|
||||
<DD>
|
||||
Display expressions which start with <I>sr</I> and end with <I>er</I>
|
||||
with foreground color <I>fgcolor</I> and optional
|
||||
background color <I>bgcolor</I>. This allows syntax highlighting to span
|
||||
multiple lines. Note that all subsequent instances of <I>sr</I> after
|
||||
an initial <I>sr</I> is found will be highlighted until the first
|
||||
instance of <I>er</I>.
|
||||
with foreground color <I>fgcolor</I> and optional background color
|
||||
<I>bgcolor</I>. This allows syntax highlighting to span multiple lines.
|
||||
Note that all subsequent instances of <I>sr</I> after an initial <I>sr</I>
|
||||
is found will be highlighted until the first instance of <I>er</I>.
|
||||
<I>
|
||||
<P>
|
||||
</DL>
|
||||
|
@ -143,7 +144,7 @@ instance of <I>er</I>.
|
|||
<H2>FILES</H2>
|
||||
|
||||
<DL COMPACT>
|
||||
<DT><I>$SYSCONFDIR/nanorc</I>
|
||||
<DT><I>SYSCONFDIR/nanorc</I>
|
||||
|
||||
<DD>
|
||||
System-wide configuration file
|
||||
|
@ -190,6 +191,6 @@ This manual page was written by Jordi Mallach <<A HREF="mailto:jordi@gnu.org"
|
|||
This document was created by
|
||||
<A HREF="http://localhost/cgi-bin/man/man2html">man2html</A>,
|
||||
using the manual pages.<BR>
|
||||
Time: 22:28:00 GMT, June 19, 2003
|
||||
Time: 21:17:00 GMT, August 24, 2003
|
||||
</BODY>
|
||||
</HTML>
|
||||
|
|
|
@ -29,9 +29,6 @@
|
|||
## Enable ~/.nano_history for saving and reading search/replace strings.
|
||||
# set historylog
|
||||
|
||||
## Use alternate keypad routines
|
||||
# set keypad
|
||||
|
||||
## Allow multiple file buffers (using ^R inserts into separate buffer).
|
||||
## You must have configured with --enable-multibuffer or --enable-extra
|
||||
## for this to work.
|
||||
|
@ -69,6 +66,9 @@
|
|||
## You can get old nano quoted-justify behavior via:
|
||||
# set quotestr "(> )+"
|
||||
|
||||
## Fix Backspace if it acts like Delete
|
||||
# set rebinddelete
|
||||
|
||||
## Do extended regular expression searches by default
|
||||
# set regexp
|
||||
|
||||
|
@ -89,9 +89,6 @@
|
|||
## Save automatically on exit, don't prompt
|
||||
# set tempfile
|
||||
|
||||
## Enable ~/.nano_history for saving and reading search/replace strings.
|
||||
# set historylog
|
||||
|
||||
## Disallow file modification, why would you want this in an rc file? ;)
|
||||
# set view
|
||||
|
||||
|
|
5
winio.c
5
winio.c
|
@ -1913,7 +1913,8 @@ void dump_buffer(const filestruct *inptr) {
|
|||
#endif /* DEBUG */
|
||||
|
||||
#ifdef DEBUG
|
||||
void dump_buffer_reverse(void) {
|
||||
void dump_buffer_reverse(void)
|
||||
{
|
||||
const filestruct *fileptr = filebot;
|
||||
|
||||
while (fileptr != NULL) {
|
||||
|
@ -1979,7 +1980,7 @@ void do_credits(void)
|
|||
"6", /* "and anyone else we forgot..." */
|
||||
"7", /* "Thank you for using nano!\n" */
|
||||
"", "", "", "",
|
||||
"(c) 1999-2002 Chris Allegretta",
|
||||
"(c) 1999-2003 Chris Allegretta",
|
||||
"", "", "", "",
|
||||
"http://www.nano-editor.org/"
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue