From: David Lawrence Ramsey Date: Sun, 31 Aug 2003 16:44:10 +0000 (+0000) Subject: documentation updates X-Git-Tag: v1.3.0~40 X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=aaad3af52362f65ee37317d7f314e03167c981a4;p=nano.git documentation updates git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1534 35c25a1d-7b9e-4130-9fde-d3aeb78583b8 --- diff --git a/ChangeLog b/ChangeLog index d4e1d807..8a599f99 100644 --- a/ChangeLog +++ b/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. diff --git a/files.c b/files.c index 4d1d98cb..8f9918d5 100644 --- a/files.c +++ b/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)) { diff --git a/global.c b/global.c index 5bdb1c07..756591a8 100644 --- a/global.c +++ b/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 */ diff --git a/nano.1 b/nano.1 index 2b452943..6dac87b5 100644 --- a/nano.1 +++ b/nano.1 @@ -3,10 +3,10 @@ .\" Chris Allegretta .\" .\" 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. .\" @@ -22,10 +22,10 @@ nano \- Nano's ANOther editor, an enhanced free Pico clone This manual page documents briefly the \fBnano\fP command. .PP .\" TeX users may be more comfortable with the \fB\fP and -.\" \fI\fP escape sequences to invoke bold face and italics, +.\" \fI\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". @@ -48,21 +48,16 @@ Enable multiple file buffers, if available. .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 @@ -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,17 +116,17 @@ 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 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) @@ -151,15 +151,14 @@ 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 .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 @@ -167,11 +166,11 @@ cases. Mainly, this will happen if \fBnano\fP receives a SIGHUP or 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 @@ -201,5 +200,5 @@ Chris Allegretta , et al (see and .I THANKS for details). This manual page was originally written by Jordi Mallach -, for the Debian GNU system (but may be -used by others). +, for the Debian GNU system (but may be used by +others). diff --git a/nano.1.html b/nano.1.html index 4c83b98d..f3ed1737 100644 --- a/nano.1.html +++ b/nano.1.html @@ -1,7 +1,7 @@ Manpage of NANO

NANO

-Section: User Commands (1)
Updated: June 19, 2003
Index +Section: User Commands (1)
Updated: August 24, 2003
Index Return to Main Contents
@@ -32,7 +32,7 @@ This manual page documents briefly the nano command. nano 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, nano also implements some missing (or disabled by default) features in Pico, such as "search and replace" and "go to line number". @@ -64,24 +64,18 @@ Enable multiple file buffers, if available. Log search and replace strings to ~/.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.
-I (--ignorercfiles)
Don't look at -$SYSCONFDIR/nanorc +SYSCONFDIR/nanorc or ~/.nanorc, if nanorc support is available. -
-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.
-M (--mac)
@@ -104,7 +98,7 @@ Enable regular expression matching for search strings, as well as
-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.
-T num (--tabsize=num) @@ -125,6 +119,12 @@ to use, if available.
Constantly show the cursor position. +
-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.
-h (--help)
@@ -132,7 +132,7 @@ Display a summary of command line options.
-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.
-k (--cut) @@ -153,19 +153,19 @@ Enable mouse support (if available for your system).
-o dir (--operatingdir=dir)
-Set operating directory. Makes nano set up something similar to a +Set operating directory. Makes nano set up something similar to a chroot.
-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.
-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 columns from the right of the screen, allowing the wrap point +cols columns from the right of the screen, allowing the wrap point to vary along with the screen width if resized.
-s prog (--speller=prog) @@ -200,9 +200,8 @@ Ignored, for compatibility with Pico.  

INITIALIZATION FILE

-nano will read initialization files in the following -order: -$SYSCONFDIR/nanorc, +nano will read initialization files in the following order: +SYSCONFDIR/nanorc, then ~/.nanorc. @@ -210,8 +209,8 @@ then Please see nanorc(5) -and the example file nanorc.sample which should be provided with -nano. +and the example file nanorc.sample which should be provided with +nano.

 

NOTES

@@ -222,11 +221,11 @@ SIGTERM or runs out of memory, when it will write the buffer into a file named 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, nano 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, nano will write all the open buffers to the respective emergency files.

  @@ -271,8 +270,8 @@ and 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).


@@ -293,6 +292,6 @@ used by others). This document was created by man2html, using the manual pages.
-Time: 22:27:55 GMT, June 19, 2003 +Time: 21:16:54 GMT, August 24, 2003 diff --git a/nano.c b/nano.c index 4db19ffc..202bab23 100644 --- a/nano.c +++ b/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; diff --git a/nano.texi b/nano.texi index 14bcfc71..ee8d5d4b 100644 --- a/nano.texi +++ b/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,10 +95,10 @@ 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}. +Email bug reports to @email{nano@@nano-editor.org}. @node Command Line Options, , Overview, Introduction @section Command Line Options @@ -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. @@ -151,7 +146,7 @@ Enable smooth scrolling. @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] @@ -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 @@ -206,21 +206,21 @@ 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. +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 @@ -249,38 +249,41 @@ Start at line number LINE instead of the default of line 1. 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. @@ -302,13 +305,13 @@ the statusbar. @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. @@ -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 @@ -375,7 +378,7 @@ find the desired file. 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. @@ -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 -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. @@ -405,13 +408,12 @@ Text selected using the Control-Caret (^^) key can be written out or 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 @@ -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. +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) @@ -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 diff --git a/nanorc.5 b/nanorc.5 index c9f4e8bd..d50a2dfb 100644 --- a/nanorc.5 +++ b/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. +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' +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 @@ -113,7 +115,7 @@ calls \fIspell\fP. 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 @@ -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 -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 @@ -158,7 +159,7 @@ Per-user configuration file .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 , et al (see diff --git a/nanorc.5.html b/nanorc.5.html index 849f89e8..af77f7dd 100644 --- a/nanorc.5.html +++ b/nanorc.5.html @@ -1,7 +1,7 @@ Manpage of NANORC

NANORC

-Section: File Formats (5)
Updated: June 19, 2003
Index +Section: File Formats (5)
Updated: August 24, 2003
Index Return to Main Contents
@@ -17,15 +17,15 @@ This manual page documents GNU nano's rcfile.

nano 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, nano also implements some missing (or disabled by default) features in Pico, such as "search and replace" and "go to line number".

-The nanorc file contains the default settings for nano. +The nanorc file contains the default settings for nano. During startup, nano will first read its system-wide settings from -$SYSCONFDIR/nanorc, +SYSCONFDIR/nanorc, and then user-specific settings from ~/.nanorc. @@ -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.

-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.

@@ -66,8 +66,6 @@ Enable ~/.nano_history for saving and reading search/replace strings. -

set/unset keypad
-Use alternate keypad routines.
set/unset multibuffer
Allow inserting files into their own buffers.
set/unset noconvert
@@ -80,20 +78,24 @@ Don't display the help lists at the bottom of the screen. Don't wrap text at all.
set operatingdir "directory"
nano will only read and write files inside directory 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.
set/unset preserve
Preserve the XON and XOFF keys (^Q and ^S).
set quotestr "string"
-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. +

set/unset 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.
set/unset regexp
Do regular expression searches by default.
set/unset smooth
@@ -104,7 +106,7 @@ calls spell.
set/unset suspend
Allow nano to be suspended with ^Z.
set tabsize n
-Use a tab size of n instead of the default (8); must be greater +Use a tab size of n instead of the default (8); must be greater than 0.
set/unset tempfile
Save automatically on exit, don't prompt. @@ -113,29 +115,28 @@ Disallow file modification.
syntax str [fileregex ... ]
-Defines a syntax named str which can be activated via the --Y flag, or will be automatically activated if the current -filename matches fileregex. All following color statements -will apply to syntax until a new syntax is defined. +Defines a syntax named str which can be activated via the -Y +flag, or will be automatically activated if the current filename matches +fileregex. All following color statements will apply to +syntax until a new syntax is defined.
color fgcolor[,bgcolor] regex ...
-For the currently defined syntax, display all expressions matching -regex with foreground color fgcolor and optional background -color bgcolor. 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 bgcolor tells +For the currently defined syntax, display all expressions matching +regex with foreground color fgcolor and optional background +color bgcolor. 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 bgcolor tells nano to attempt to use a transparent background.
color fgcolor[,bgcolor] start=sr end=er
-Display expressions which start with sr and end with er -with foreground color fgcolor and optional -background color bgcolor. This allows syntax highlighting to span -multiple lines. Note that all subsequent instances of sr after -an initial sr is found will be highlighted until the first -instance of er. +Display expressions which start with sr and end with er +with foreground color fgcolor and optional background color +bgcolor. This allows syntax highlighting to span multiple lines. +Note that all subsequent instances of sr after an initial sr +is found will be highlighted until the first instance of er.

@@ -143,7 +144,7 @@ instance of er.

FILES

-
$SYSCONFDIR/nanorc +
SYSCONFDIR/nanorc
System-wide configuration file @@ -161,7 +162,7 @@ Per-user configuration file

-/usr/share/doc/nano/examples/nanorc.sample (or equivalent on your +/usr/share/doc/nano/examples/nanorc.sample (or equivalent on your system)  

AUTHOR

@@ -190,6 +191,6 @@ This manual page was written by Jordi Mallach <man2html, using the manual pages.
-Time: 22:28:00 GMT, June 19, 2003 +Time: 21:17:00 GMT, August 24, 2003 diff --git a/nanorc.sample b/nanorc.sample index 93deea9c..9709ce05 100644 --- a/nanorc.sample +++ b/nanorc.sample @@ -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 diff --git a/winio.c b/winio.c index 1dac31d8..4ebf3fb1 100644 --- a/winio.c +++ b/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/" };