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
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.
return -1;
}
#endif
- if (append == 0 && strcmp(answer, filename) != 0) {
+ if (append == 0 && strcmp(answer, filename)) {
struct stat st;
if (!stat(answer, &st)) {
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
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 */
.\" 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.
.\"
This manual page documents briefly the \fBnano\fP command.
.PP
.\" TeX users may be more comfortable with the \fB<whatever>\fP and
-.\" \fI<whatever>\fP escape sequences to invoke bold face and italics,
+.\" \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".
.B \-H (\-\-historylog)
Log search and replace strings to
.I ~/.nano_history
-so they may be stored for later editing, if nanorc support is
+so they may be stored for later editing, if nanorc support is
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
\\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)
.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)
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
screen, less eight. If this value is negative, wrapping will occur at
-\fIcols\fP columns from the right of the screen, allowing the wrap point
+\fIcols\fP columns from the right of the screen, allowing the wrap point
to vary along with the screen width if resized.
.TP
.B \-s \fIprog\fP (\-\-speller=\fIprog\fP)
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
.BR nanorc (5)
-and the example file \fBnanorc.sample\fP which should be provided with
-\fBnano\fP.
+and the example file \fBnanorc.sample\fP which should be provided with
+\fBnano\fP.
.SH NOTES
\fBnano\fP will try to dump the buffer into an emergency file in some
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
-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
-multibuffer mode, \fBnano\fP will write all the open buffers to the
+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
+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
+multibuffer mode, \fBnano\fP will write all the open buffers to the
respective emergency files.
.SH BUGS
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).
<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>
<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".
Log search and replace strings to
<I>~/.nano_history</I>
-so they may be stored for later editing, if nanorc support is
+so they may be stored for later editing, if nanorc support is
configured.
<DT><B>-I (--ignorercfiles)</B>
<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>
<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>)
<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>
<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>
<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>
Wrap lines at column <I>cols</I>. By default, this is the width of the
screen, less eight. If this value is negative, wrapping will occur at
-<I>cols</I> columns from the right of the screen, allowing the wrap point
+<I>cols</I> columns from the right of the screen, allowing the wrap point
to vary along with the screen width if resized.
<DT><B>-s </B><I>prog</I> (--speller=<I>prog</I>)
<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>.
Please see
<B><A HREF="http://localhost/cgi-bin/man/man2html?5+nanorc">nanorc</A></B>(5)
-and the example file <B>nanorc.sample</B> which should be provided with
-<B>nano</B>.
+and the example file <B>nanorc.sample</B> which should be provided with
+<B>nano</B>.
<P>
<A NAME="lbAG"> </A>
<H2>NOTES</H2>
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
-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
-multibuffer mode, <B>nano</B> will write all the open buffers to the
+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
+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
+multibuffer mode, <B>nano</B> will write all the open buffers to the
respective emergency files.
<P>
<A NAME="lbAH"> </A>
<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>
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>
"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);
#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;
@smallbook
@set EDITION 0.1
@set VERSION 1.2.2
-@set UPDATED 17 Jan 2003
+@set UPDATED 24 Aug 2003
@dircategory Editors
@direntry
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}.
+Email bug reports to @email{nano@@nano-editor.org}.
@node Command Line Options, , Overview, Introduction
@section Command Line Options
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.
@item -T [num], --tabsize=[num]
Set the displayed tab length to [num] columns.
-@item -V, --version
+@item -V, --version
Print the version number and copyright and quit.
@item -Y, --syntax=[str]
@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.
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
@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.
+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.
-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
All key sequences in @code{nano} are entered using the keyboard.
@code{nano} is a ``modeless'' editor. All keys with the exception of
Control and Meta key sequences will enter text into the file being
-edited.
+edited.
@node Special Functions, The Titlebar, Entering Text, Editor Basics
@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
+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.
+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.
@section Shortcut Lists
The Shortcut Lists are the two lines at the bottom of the screen which
-show some of the more commonly used functions in the editor.
+show some of the more commonly used functions in the editor.
@node Online Help, Feature Toggles, Editor Basics, Top
@chapter Online Help
The online help system in @code{nano} is available by pressing ^G.
-It is fairly self explanatory, documenting the various parts of the
+It is fairly self explanatory, documenting the various parts of the
editor and available keystrokes. Navigation is via the ^Y (Page Up)
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
Basic movement in the file browser is accomplished with the arrow keys
and page up/down. The behavior of the enter (or `s') key varies by what
is currently selected. If the currently selected object is a directory,
-the file browser will enter and display the contents of the directory.
+the file browser will enter and display the contents of the directory.
If the object is a file, this filename and path are copied to the
statusbar and the file browser is exited.
@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
-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
+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
hitting the up arrow key once, the old method was removed completely.
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.
+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.
@item Cursor Position Display
The output of the "Display Cursor Position" in @code{nano} displays
@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.
+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.
@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)
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
.\" 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
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.
+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.
.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
.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'
+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
Allow nano to be suspended with ^Z.
.TP
\fBset tabsize \fIn\fP\fP
-Use a tab size of \fIn\fP instead of the default (8); must be greater
+Use a tab size of \fIn\fP instead of the default (8); must be greater
than 0.
.TP
\fBset/unset tempfile\fP
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
-terminal supports transparency, not specifying a \fIbgcolor\fP tells
+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
+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.
+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.
\fI
.SH FILES
.TP
-.I $SYSCONFDIR/nanorc
+.I SYSCONFDIR/nanorc
System-wide configuration file
.TP
.I ~/.nanorc
.TP
\fBnano\fP(1)
.PP
-\fI/usr/share/doc/nano/examples/nanorc.sample\fP (or equivalent on your
+\fI/usr/share/doc/nano/examples/nanorc.sample\fP (or equivalent on your
system)
.SH AUTHOR
Chris Allegretta <chrisa@asty.org>, et al (see
<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>
<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".
<P>
-The <I>nanorc</I> file contains the default settings for <B>nano</B>.
+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>.
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>
<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>
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'
+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>
<DT><B>set/unset suspend</B><DD>
Allow nano to be suspended with ^Z.
<DT><B>set tabsize </B><I>n</I><DD>
-Use a tab size of <I>n</I> instead of the default (8); must be greater
+Use a tab size of <I>n</I> instead of the default (8); must be greater
than 0.
<DT><B>set/unset tempfile</B><DD>
Save automatically on exit, don't prompt.
<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
-terminal supports transparency, not specifying a <I>bgcolor</I> tells
+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
+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>.
+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>.
<I>
<P>
</DL>
<H2>FILES</H2>
<DL COMPACT>
-<DT><I>$SYSCONFDIR/nanorc</I>
+<DT><I>SYSCONFDIR/nanorc</I>
<DD>
System-wide configuration file
</DL>
<P>
-<I>/usr/share/doc/nano/examples/nanorc.sample</I> (or equivalent on your
+<I>/usr/share/doc/nano/examples/nanorc.sample</I> (or equivalent on your
system)
<A NAME="lbAG"> </A>
<H2>AUTHOR</H2>
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>
## 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.
## 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
## 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
#endif /* DEBUG */
#ifdef DEBUG
-void dump_buffer_reverse(void) {
+void dump_buffer_reverse(void)
+{
const filestruct *fileptr = filebot;
while (fileptr != NULL) {
"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/"
};