Commit 0084eaa9 authored by David Lawrence Ramsey's avatar David Lawrence Ramsey
Browse files

documentation updates

git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1317 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
parent 749def4e
Showing with 389 additions and 825 deletions
+389 -825
...@@ -2,14 +2,31 @@ CVS code - ...@@ -2,14 +2,31 @@ CVS code -
- General: - General:
- Translation updates (see po/ChangeLog for details). - Translation updates (see po/ChangeLog for details).
- Forward-ported Chris' --disable-wrapping-as-root option from - Forward-ported Chris' --disable-wrapping-as-root option from
1.0.9. Per Jordi's suggestions, have it override /etc/nanorc 1.0.9. Per Jordi's suggestions, have it override
but not ~/.nanorc. (DLR) $SYSCONFDIR/nanorc but not ~/.nanorc. (DLR)
- Change all references to /etc/nanorc in the documentation to
$SYSCONFDIR/nanorc. (DLR)
nano.c:
version()
- Remove obsolete reference to --enable-undo. (David Benbennick)
- winio.c:
do_credits()
- Add David Benbennick to credits. (DLR)
- nanorc.sample:
- Added comment to explain the non-escaping of quotes in
color regexes, based on info provided by David Benbennick.
(DLR)
- faq.html:
- Miscellaneous fixes and updates for typos and broken links.
It is now fully compliant with HTML 4.10 Transitional. (DLR)
- nano.texi:
- Typo fixes and updates. (David Benbennick)
GNU nano 1.1.12 - 10/24/2002 GNU nano 1.1.12 - 10/24/2002
- General: - General:
- Translation updates (see po/ChangeLog for details). - Translation updates (see po/ChangeLog for details).
- Remove malloc.h, as it's unneeded and just causes annoyances on - Remove malloc.h, as it's unneeded and just causes annoyances on
*BSD systems. Added stdlib.h to global.c *BSD systems. Added stdlib.h to global.c.
- Added Meta-Y toggle to disable/enable color syntax highlighting - Added Meta-Y toggle to disable/enable color syntax highlighting
completely. This may eventually be per-buffer, but that's too completely. This may eventually be per-buffer, but that's too
complicated for a feature freeze. complicated for a feature freeze.
...@@ -197,6 +214,8 @@ GNU nano 1.1.11 - 10/01/2002 ...@@ -197,6 +214,8 @@ GNU nano 1.1.11 - 10/01/2002
Benbennick) Benbennick)
- faq.html: - faq.html:
- Typo fix. (DLR) - Typo fix. (DLR)
- AUTHORS:
- Add David Benbennick. (Jordi and Chris)
- TODO: - TODO:
- Add entry in the 1.4 section for Pico's paragraph searching - Add entry in the 1.4 section for Pico's paragraph searching
ability (at the search prompt, ^W goes to the paragraph's ability (at the search prompt, ^W goes to the paragraph's
...@@ -287,8 +306,8 @@ GNU nano 1.1.10 - 07/25/2002 ...@@ -287,8 +306,8 @@ GNU nano 1.1.10 - 07/25/2002
printed as-is and be interpreted as commands by xterm, which printed as-is and be interpreted as commands by xterm, which
will corrupt the display.) (DLR) will corrupt the display.) (DLR)
- Add command line option -I/--ignorercfiles to ignore - Add command line option -I/--ignorercfiles to ignore
/etc/nanorc and ~/.nanorc. (Carl Drinkwater). Fix to parsing $SYSCONFDIR/nanorc and ~/.nanorc. (Carl Drinkwater). Fix to
getopt args (DLR). parsing getopt args (DLR).
- Fix minor bugs with importing certain text files in Mac - Fix minor bugs with importing certain text files in Mac
format. (DLR) format. (DLR)
- files.c: - files.c:
...@@ -749,7 +768,7 @@ GNU nano 1.1.7 - 03/05/2002 ...@@ -749,7 +768,7 @@ GNU nano 1.1.7 - 03/05/2002
- Preliminary quoting support for justify. New arg -Q, --quotestr, - Preliminary quoting support for justify. New arg -Q, --quotestr,
changes to do_justify(), global variable quotestr(). changes to do_justify(), global variable quotestr().
- Makefile.am: - Makefile.am:
- Add SYSCONFDIR to DEFS, so we can have an /etc/nanorc. - Add SYSCONFDIR to DEFS, so we can have an $SYSCONFDIR/nanorc.
- Change localedir line to 1.0's version. - Change localedir line to 1.0's version.
- Moved m4/ stuff to its own m4/Makefile.am. - Moved m4/ stuff to its own m4/Makefile.am.
- m4/aclocal_inc.m4: - m4/aclocal_inc.m4:
......
...@@ -4,7 +4,7 @@ INSTRUCTIONS TO COMPILE AND INSTALL NANO CVS VERSIONS ...@@ -4,7 +4,7 @@ INSTRUCTIONS TO COMPILE AND INSTALL NANO CVS VERSIONS
GNU nano is available from CVS, but building this needs a bit GNU nano is available from CVS, but building this needs a bit
more care than the official stable and unstable tarballs. more care than the official stable and unstable tarballs.
To succesfully compile GNU nano from CVS, you'll need the To successfully compile GNU nano from CVS, you'll need the
following packages: following packages:
- autoconf (version >= 2.52) - autoconf (version >= 2.52)
...@@ -26,9 +26,9 @@ and the nano tree will download. ...@@ -26,9 +26,9 @@ and the nano tree will download.
If you want to checkout the stable CVS branch, append -r nano_1_0_branch: If you want to checkout the stable CVS branch, append -r nano_1_0_branch:
$ cvs -z3 -d:pserver:anonymous@subversions.gnu.org:/cvsroot/nano checkout -r nano_1_0_branch nano $ cvs -z3 -d:pserver:anonymous@subversions.gnu.org:/cvsroot/nano checkout -r nano_1_0_branch nano
Once you have the sources in the "nano" directory, cd into it, and execute Once you have the sources in the "nano" directory, cd into it, and
the "autogen.sh" script in the top dir. This will setup a configure script execute the "autogen.sh" script in the top dir. This will setup a
and Makefile.in, and you will be ready to compile with configure script and Makefile.in, and you will be ready to compile with
$ ./configure [--add-options-here] && make $ ./configure [--add-options-here] && make
Once it's done compiling, Once it's done compiling,
$ make install $ make install
......
...@@ -26,7 +26,7 @@ AC_ARG_ENABLE(debug, ...@@ -26,7 +26,7 @@ AC_ARG_ENABLE(debug,
fi]) fi])
if test "$debug_support" != "yes"; then if test "$debug_support" != "yes"; then
AC_DEFINE(NDEBUG, 1, [Shut up the assert warnings :-)]) AC_DEFINE(NDEBUG, 1, [Shut up the assert warnings :-)])
fi fi
AC_ARG_ENABLE(extra, AC_ARG_ENABLE(extra,
......
...@@ -268,7 +268,7 @@ int do_cut_text(void) ...@@ -268,7 +268,7 @@ int do_cut_text(void)
#ifdef DEBUG #ifdef DEBUG
dump_buffer(cutbuffer); dump_buffer(cutbuffer);
#endif #endif
if (fileptr == fileage) if (fileptr == fileage)
fileage = current; fileage = current;
else else
......
This diff is collapsed.
...@@ -1333,7 +1333,7 @@ int write_file(const char *name, int tmp, int append, int nonamechange) ...@@ -1333,7 +1333,7 @@ int write_file(const char *name, int tmp, int append, int nonamechange)
#ifndef NANO_SMALL #ifndef NANO_SMALL
/* We backup only if the backup toggle is set, the file isn't /* We backup only if the backup toggle is set, the file isn't
temporary, and the file already exists. Furthermore, if we aren't temporary, and the file already exists. Furthermore, if we aren't
appending, prepending, or writing a selection, also backup only if appending, prepending, or writing a selection, we backup only if
the file has not been modified by someone else since nano opened the file has not been modified by someone else since nano opened
it. */ it. */
if (ISSET(BACKUP_FILE) && !tmp && realexists == 0 && if (ISSET(BACKUP_FILE) && !tmp && realexists == 0 &&
...@@ -1381,7 +1381,7 @@ int write_file(const char *name, int tmp, int append, int nonamechange) ...@@ -1381,7 +1381,7 @@ int write_file(const char *name, int tmp, int append, int nonamechange)
fclose(f); fclose(f);
if (chmod(backupname, originalfilestat.st_mode) == -1) if (chmod(backupname, originalfilestat.st_mode) == -1)
statusbar(_("Could not set permissions %o on backup %s: %s"), statusbar(_("Could not set permissions %o on backup %s: %s"),
originalfilestat.st_mode, backupname, originalfilestat.st_mode, backupname,
strerror(errno)); strerror(errno));
...@@ -1803,7 +1803,7 @@ int do_writeout(const char *path, int exiting, int append) ...@@ -1803,7 +1803,7 @@ int do_writeout(const char *path, int exiting, int append)
/* Here's where we allow the selected text to be written to /* Here's where we allow the selected text to be written to
a separate file. */ a separate file. */
if (ISSET(MARK_ISSET) && !exiting) { if (ISSET(MARK_ISSET) && !exiting) {
filestruct *fileagebak = fileage; filestruct *fileagebak = fileage;
filestruct *filebotbak = filebot; filestruct *filebotbak = filebot;
filestruct *cutback = cutbuffer; filestruct *cutback = cutbuffer;
int oldmod = ISSET(MODIFIED); int oldmod = ISSET(MODIFIED);
...@@ -2749,7 +2749,7 @@ char *do_browser(const char *inpath) ...@@ -2749,7 +2749,7 @@ char *do_browser(const char *inpath)
(int) st.st_size >> 10); (int) st.st_size >> 10);
} }
/* Hilight the currently selected file/dir */ /* Highlight the currently selected file/dir */
if (j == selected) if (j == selected)
wattron(edit, A_REVERSE); wattron(edit, A_REVERSE);
waddstr(edit, foo); waddstr(edit, foo);
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
.\" Public License for copying conditions. There is NO warranty. .\" Public License for copying conditions. There is NO warranty.
.\" .\"
.\" $Id$ .\" $Id$
.TH NANO 1 "July 30, 2002" .TH NANO 1 "November 1, 2002"
.\" Please adjust this date whenever revising the manpage. .\" Please adjust this date whenever revising the manpage.
.\" .\"
.SH NAME .SH NAME
...@@ -42,11 +42,12 @@ Write file in DOS format. ...@@ -42,11 +42,12 @@ Write file in DOS format.
Enable multiple file buffers, if available. Enable multiple file buffers, if available.
.TP .TP
.B \-I (\-\-ignorercfiles) .B \-I (\-\-ignorercfiles)
Don't look at /etc/nanorc or ~/.nanorc, if nanorc support is available. Don't look at $SYSCONFDIR/nanorc or ~/.nanorc, if nanorc support is
available.
.TP .TP
.B \-K (\-\-keypad) .B \-K (\-\-keypad)
Do not use the ncurses keypad() call unless necessary. Try this flag if 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 you find that the arrow keys on the numeric keypad do not work for you
under nano. under nano.
.TP .TP
.B \-M (\-\-mac) .B \-M (\-\-mac)
......
...@@ -3,7 +3,7 @@ Content-type: text/html ...@@ -3,7 +3,7 @@ Content-type: text/html
<HTML><HEAD><TITLE>Manpage of NANO</TITLE> <HTML><HEAD><TITLE>Manpage of NANO</TITLE>
</HEAD><BODY> </HEAD><BODY>
<H1>NANO</H1> <H1>NANO</H1>
Section: User Commands (1)<BR>Updated: October 13, 2002<BR><A HREF="#index">Index</A> Section: User Commands (1)<BR>Updated: November 1, 2002<BR><A HREF="#index">Index</A>
<A HREF="http://localhost/cgi-bin/man/man2html">Return to Main Contents</A><HR> <A HREF="http://localhost/cgi-bin/man/man2html">Return to Main Contents</A><HR>
...@@ -59,12 +59,13 @@ Enable multiple file buffers, if available. ...@@ -59,12 +59,13 @@ Enable multiple file buffers, if available.
<DT><B>-I (--ignorercfiles)</B> <DT><B>-I (--ignorercfiles)</B>
<DD> <DD>
Don't look at /etc/nanorc or ~/.nanorc, if nanorc support is available. Don't look at $SYSCONFDIR/nanorc or ~/.nanorc, if nanorc support is
available.
<DT><B>-K (--keypad)</B> <DT><B>-K (--keypad)</B>
<DD> <DD>
Do not use the ncurses keypad() call unless necessary. Try this flag if 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 you find that the arrow keys on the numeric keypad do not work for you
under nano. under nano.
<DT><B>-M (--mac)</B> <DT><B>-M (--mac)</B>
...@@ -235,6 +236,6 @@ used by others). ...@@ -235,6 +236,6 @@ used by others).
This document was created by This document was created by
<A HREF="http://localhost/cgi-bin/man/man2html">man2html</A>, <A HREF="http://localhost/cgi-bin/man/man2html">man2html</A>,
using the manual pages.<BR> using the manual pages.<BR>
Time: 16:04:40 GMT, October 13, 2002 Time: 17:00:52 GMT, November 01, 2002
</BODY> </BODY>
</HTML> </HTML>
...@@ -685,7 +685,7 @@ void version(void) ...@@ -685,7 +685,7 @@ void version(void)
printf(_(" GNU nano version %s (compiled %s, %s)\n"), printf(_(" GNU nano version %s (compiled %s, %s)\n"),
VERSION, __TIME__, __DATE__); VERSION, __TIME__, __DATE__);
printf(_ printf(_
(" Email: nano@nano-editor.org Web: http://www.nano-editor.org")); (" Email: nano@nano-editor.org Web: http://www.nano-editor.org/"));
printf(_("\n Compiled options:")); printf(_("\n Compiled options:"));
#ifdef DEBUG #ifdef DEBUG
...@@ -737,9 +737,6 @@ void version(void) ...@@ -737,9 +737,6 @@ void version(void)
#ifdef ENABLE_NANORC #ifdef ENABLE_NANORC
printf(" --enable-nanorc"); printf(" --enable-nanorc");
#endif #endif
#ifdef ENABLE_UNDO
printf(" --enable-undo");
#endif
#ifdef USE_SLANG #ifdef USE_SLANG
printf(" --with-slang"); printf(" --with-slang");
#endif #endif
...@@ -785,9 +782,10 @@ int open_pipe(const char *command) ...@@ -785,9 +782,10 @@ int open_pipe(const char *command)
struct termios term, newterm; struct termios term, newterm;
#endif /* _POSIX_VDISABLE */ #endif /* _POSIX_VDISABLE */
int cancel_sigs = 0; int cancel_sigs = 0;
/* cancel_sigs==1 means that sigaction failed without changing the /* cancel_sigs == 1 means that sigaction() failed without changing
* signal handlers. cancel_sigs==2 means the signal handler was * the signal handlers. cancel_sigs == 2 means the signal handler
* changed, but the tcsetattr didn't succeed. * was changed, but the tcsetattr didn't succeed.
*
* I use this variable since it is important to put things back when * I use this variable since it is important to put things back when
* we finish, even if we get errors. */ * we finish, even if we get errors. */
...@@ -806,7 +804,7 @@ int open_pipe(const char *command) ...@@ -806,7 +804,7 @@ int open_pipe(const char *command)
dup2(fd[1], fileno(stderr)); dup2(fd[1], fileno(stderr));
/* If execl() returns at all, there was an error. */ /* If execl() returns at all, there was an error. */
execl("/bin/sh","sh","-c",command,0); execl("/bin/sh", "sh", "-c", command, 0);
exit(0); exit(0);
} }
...@@ -822,12 +820,12 @@ int open_pipe(const char *command) ...@@ -822,12 +820,12 @@ int open_pipe(const char *command)
/* Before we start reading the forked command's output, we set /* Before we start reading the forked command's output, we set
* things up so that ^C will cancel the new process. */ * things up so that ^C will cancel the new process. */
if (sigaction(SIGINT, NULL, &newaction)==-1) { if (sigaction(SIGINT, NULL, &newaction) == -1) {
cancel_sigs = 1; cancel_sigs = 1;
nperror("sigaction"); nperror("sigaction");
} else { } else {
newaction.sa_handler = cancel_fork; newaction.sa_handler = cancel_fork;
if (sigaction(SIGINT, &newaction, &oldaction)==-1) { if (sigaction(SIGINT, &newaction, &oldaction) == -1) {
cancel_sigs = 1; cancel_sigs = 1;
nperror("sigaction"); nperror("sigaction");
} }
...@@ -871,7 +869,7 @@ int open_pipe(const char *command) ...@@ -871,7 +869,7 @@ int open_pipe(const char *command)
nperror("tcsetattr"); nperror("tcsetattr");
#endif /* _POSIX_VDISABLE */ #endif /* _POSIX_VDISABLE */
if (cancel_sigs!=1 && sigaction(SIGINT, &oldaction, NULL) == -1) if (cancel_sigs != 1 && sigaction(SIGINT, &oldaction, NULL) == -1)
nperror("sigaction"); nperror("sigaction");
return 0; return 0;
...@@ -1950,13 +1948,13 @@ size_t indent_length(const char *line) ...@@ -1950,13 +1948,13 @@ size_t indent_length(const char *line)
* it maintains 2 after a . ! or ?). Note the terminating \0 * it maintains 2 after a . ! or ?). Note the terminating \0
* counts as a space. * counts as a space.
* *
* If !changes_allowed and justify_format needs to make a change, it * If !changes_allowed and justify_format() needs to make a change, it
* returns 1, otherwise returns 0. * returns 1, otherwise returns 0.
* *
* If changes_allowed, justify_format() might make line->data * If changes_allowed, justify_format() might make line->data
* shorter, and change the actual pointer with null_at(). * shorter, and change the actual pointer with null_at().
* *
* justify_format will not look at the first skip characters of line. * justify_format() will not look at the first skip characters of line.
* skip should be at most strlen(line->data). The skip+1st character must * skip should be at most strlen(line->data). The skip+1st character must
* not be whitespace. */ * not be whitespace. */
int justify_format(int changes_allowed, filestruct *line, size_t skip) int justify_format(int changes_allowed, filestruct *line, size_t skip)
...@@ -2167,7 +2165,7 @@ int break_line(const char *line, int goal, int force) ...@@ -2167,7 +2165,7 @@ int break_line(const char *line, int goal, int force)
return -1; return -1;
} }
/* Perhaps the character after space_loc is a space. But because /* Perhaps the character after space_loc is a space. But because
* of justify_format, there can be only two adjacent. */ * of justify_format(), there can be only two adjacent. */
if (*(line - cur_loc + space_loc + 1) == ' ' || if (*(line - cur_loc + space_loc + 1) == ' ' ||
*(line - cur_loc + space_loc + 1) == '\0') *(line - cur_loc + space_loc + 1) == '\0')
space_loc++; space_loc++;
...@@ -2361,7 +2359,7 @@ int do_justify(void) ...@@ -2361,7 +2359,7 @@ int do_justify(void)
* change the line, just say whether there are changes to be * change the line, just say whether there are changes to be
* made. If there are, we do backup_lines(), which copies the * made. If there are, we do backup_lines(), which copies the
* original paragraph to the cutbuffer for unjustification, and * original paragraph to the cutbuffer for unjustification, and
* then calls justify_format on the remaining lines. */ * then calls justify_format() on the remaining lines. */
if (first_mod_line == NULL && if (first_mod_line == NULL &&
justify_format(0, current, indent_len)) justify_format(0, current, indent_len))
first_mod_line = backup_lines(current, par_len, quote_len); first_mod_line = backup_lines(current, par_len, quote_len);
...@@ -2660,7 +2658,7 @@ void signal_init(void) ...@@ -2660,7 +2658,7 @@ void signal_init(void)
#ifdef _POSIX_VDISABLE #ifdef _POSIX_VDISABLE
tcgetattr(0, &term); tcgetattr(0, &term);
/* Ignore ^s, much to Chris' chagrin */ /* Ignore ^S, much to Chris' chagrin */
term.c_cc[VSTOP] = _POSIX_VDISABLE; term.c_cc[VSTOP] = _POSIX_VDISABLE;
#ifdef VDSUSP #ifdef VDSUSP
......
...@@ -40,7 +40,7 @@ manual provided the copyright notice and this permission notice are ...@@ -40,7 +40,7 @@ manual provided the copyright notice and this permission notice are
preserved on all copies. preserved on all copies.
@iftex @iftex
Permission is granted to process this file through TeX and print the Permission is granted to process this file through @TeX{} and print the
results, provided the printed document carries copying permission notice results, provided the printed document carries copying permission notice
identical to this one except for the removal of this paragraph (this identical to this one except for the removal of this paragraph (this
paragraph not being relevant to the printed manual). paragraph not being relevant to the printed manual).
...@@ -56,7 +56,7 @@ into another language, under the above conditions for modified versions, ...@@ -56,7 +56,7 @@ into another language, under the above conditions for modified versions,
except that this permission notice may be stated in a translation except that this permission notice may be stated in a translation
approved by the Foundation. approved by the Foundation.
You may contact the author by: You may contact the author by
e-mail: @email{chrisa@@asty.org}@* e-mail: @email{chrisa@@asty.org}@*
@end titlepage @end titlepage
...@@ -91,12 +91,12 @@ internationalization support, and filename tab completion. ...@@ -91,12 +91,12 @@ internationalization support, and filename tab completion.
@node Overview, Command Line Options, Introduction, Introduction @node Overview, Command Line Options, Introduction, Introduction
@section Overview @section Overview
@code{nano} [GNU long option] [option] +LINE [ @var{ file ...} ] @code{nano} +LINE [GNU long option] [option] [ @var{file ...} ]
The original goal for @code{nano} was a complete bug-for-bug compatible The original goal for @code{nano} was a complete bug-for-bug compatible
emulation of Pico, but consistency is now a slightly higher priority. emulation of Pico, but consistency is now a slightly higher priority.
There is a flag to implement (nearly) complete Pico emulation, (option -p There is a flag to implement (nearly) complete Pico emulation, (option -p
or GNU long option --pico). This can also be toggled from within or GNU long option @code{--pico}). This can also be toggled from within
@code{nano} by typing Meta-P. @xref{Pico Compatibility}, for more @code{nano} by typing Meta-P. @xref{Pico Compatibility}, for more
info. info.
...@@ -120,7 +120,8 @@ Write file in DOS format. ...@@ -120,7 +120,8 @@ Write file in DOS format.
Enable multiple file buffers, if available. Enable multiple file buffers, if available.
@item -I, --ignorercfiles @item -I, --ignorercfiles
Don't look at /etc/nanorc or ~/.nanorc, if nanorc support is available. Don't look at $SYSCONFDIR/nanorc or ~/.nanorc, if nanorc support is
available.
@item -K, --keypad @item -K, --keypad
Do not use the ncurses keypad() call unless necessary. Try this flag if Do not use the ncurses keypad() call unless necessary. Try this flag if
...@@ -135,16 +136,19 @@ Do not convert files from DOS/Mac format. ...@@ -135,16 +136,19 @@ Do not convert files from DOS/Mac format.
@item -Q [str], --quotestr [str] @item -Q [str], --quotestr [str]
Set the quoting string for justifying. The default is Set the quoting string for justifying. The default is
"^([ \t]*[|>:@}#])+" if regular expression support is available, or
"> " otherwise.
Set the quoting string for justifying. The default is "> ". @quotation
@code{^([ \t]*[|>:@}#])+}
@end quotation
if regular expression support is available, or ``> '' otherwise. Note
that @code{\t} above stands for a literal Tab character.
@item -R, --regexp @item -R, --regexp
Turns on regular expression search and search/replace. Turn on regular expression search and search/replace.
@item -S, --smooth @item -S, --smooth
Enables smooth scrolling. Enable smooth scrolling.
@item -T [num], --tabsize=[num] @item -T [num], --tabsize=[num]
Set the displayed tab length to [num] columns. Set the displayed tab length to [num] columns.
...@@ -245,7 +249,7 @@ Start at line number LINE instead of the default of line 1. ...@@ -245,7 +249,7 @@ Start at line number LINE instead of the default of line 1.
@section Entering Text @section Entering Text
All key sequences in @code{nano} are entered using the keyboard. All key sequences in @code{nano} are entered using the keyboard.
@code{nano} is a "modeless" editor, all keys with the exception of @code{nano} is a ``modeless'' editor. All keys with the exception of
Control and Meta key sequences will enter text into the file being Control and Meta key sequences will enter text into the file being
edited. edited.
...@@ -265,7 +269,7 @@ Meta key sequences can be entered in a number of ...@@ -265,7 +269,7 @@ Meta key sequences can be entered in a number of
possible ways: Pressing the Escape key, then releasing it and pressing possible ways: Pressing the Escape key, then releasing it and pressing
the desired key, or holding down the Alt key while pressing the desired the desired key, or holding down the Alt key while pressing the desired
key. This varies from keyboard to keyboard, and certain commercial key. This varies from keyboard to keyboard, and certain commercial
operating systems "swallow" the Alt key so that it never reaches the operating systems ``swallow'' the Alt key so that it never reaches the
application. If your operating system does this, you should use the application. If your operating system does this, you should use the
Escape key to generate Meta key sequences. Escape key to generate Meta key sequences.
@end itemize @end itemize
...@@ -276,11 +280,11 @@ Escape key to generate Meta key sequences. ...@@ -276,11 +280,11 @@ Escape key to generate Meta key sequences.
The titlebar is the line displayed at the top of the editor. There are 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 three sections: left, center and right. The section on the left displays
the version of @code{nano} being used. The center section displays the 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. 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 The section on the right will display ``Modified'' if the file has been
modified since it was last saved or opened. modified since it was last saved or opened.
Special modes: When @code{nano} is in "File browser" mode, the center Special modes: When @code{nano} is in ``File browser'' mode, the center
section will display the current directory instead of the filename. section will display the current directory instead of the filename.
@xref{The File Browser}. @xref{The File Browser}.
...@@ -288,7 +292,7 @@ section will display the current directory instead of the filename. ...@@ -288,7 +292,7 @@ section will display the current directory instead of the filename.
@section The Statusbar @section The Statusbar
The statusbar is located three lines from the bottom of the screen (or The statusbar is located three lines from the bottom of the screen (or
the bottom line in Expert Mode. @xref{Expert Mode}, for more info. the bottom line in Expert Mode. @xref{Expert Mode}, for more info).
The Statusbar shows important and informational messages. Any error The Statusbar shows important and informational messages. Any error
messages that occur from using the editor will appear on the statusbar. messages that occur from using the editor will appear on the statusbar.
...@@ -301,7 +305,7 @@ the statusbar. ...@@ -301,7 +305,7 @@ the statusbar.
The Shortcut Lists are the two lines at the bottom of the screen which 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. The exact show some of the more commonly used functions in the editor. The exact
functions which are displayed depend on whether Pico Compatibility Mode functions which are displayed depend on whether Pico Compatibility
mode is enabled. @xref{Pico Compatibility}, for more info. mode is enabled. @xref{Pico Compatibility}, for more info.
@node Online Help, Feature Toggles, Editor Basics, Top @node Online Help, Feature Toggles, Editor Basics, Top
...@@ -318,47 +322,47 @@ and ^V (Page Down) keys. ^X exits the help system. ...@@ -318,47 +322,47 @@ and ^V (Page Down) keys. ^X exits the help system.
Toggles allow you to change certain aspects of the editor that Toggles allow you to change certain aspects of the editor that
would normally be done via command line flags. They are invoked via would normally be done via command line flags. They are invoked via
certain Meta key sequenced. @xref{Special Functions}, for more info. certain Meta key sequences. @xref{Special Functions}, for more info.
The following global toggles are available: The following global toggles are available:
@table @code @table @code
@item Backup File Toggle (Meta-B) @item Backup File Toggle (Meta-B)
toggles the -B (--backup) command line flag. toggles the -B (@code{--backup}) command line flag.
@item DOS Format Toggle (Meta-D) @item DOS Format Toggle (Meta-D)
toggles the -D (--dos) command line flag. toggles the -D (@code{--dos}) command line flag.
@item Multiple Files Toggle (Meta-F) @item Multiple Files Toggle (Meta-F)
toggles the -F (--multibuffer) command line flag. toggles the -F (@code{--multibuffer}) command line flag.
@item AutoIndent Toggle (Meta-I) @item AutoIndent Toggle (Meta-I)
toggles the -i (--autoindent) command line flag. toggles the -i (@code{--autoindent}) command line flag.
@item Cut To End Toggle (Meta-K) @item Cut To End Toggle (Meta-K)
toggles the -k (--cut) command line flag. toggles the -k (@code{--cut}) command line flag.
@item Mouse Toggle (Meta-M) @item Mouse Toggle (Meta-M)
toggles the -m (--mouse) command line flag. toggles the -m (@code{--mouse}) command line flag.
@item Mac Format Toggle (Meta-O) @item Mac Format Toggle (Meta-O)
toggles the -M (--mac) command line flag. toggles the -M (@code{--mac}) command line flag.
@item Pico Mode Toggle (Meta-P) @item Pico Mode Toggle (Meta-P)
toggles the -p (--pico) command line flag. toggles the -p (@code{--pico}) command line flag.
@xref{Pico Compatibility}, for more info. @xref{Pico Compatibility}, for more info.
@item Smooth Scrolling Toggle (Meta-S) @item Smooth Scrolling Toggle (Meta-S)
toggles the -s (--smooth) command line flag. toggles the -S (@code{--smooth}) command line flag.
@item AutoWrap Toggle (Meta-W) @item AutoWrap Toggle (Meta-W)
toggles the -w (--nowrap) command line flag. toggles the -w (@code{--nowrap}) command line flag.
@item Expert/Nohelp Toggle (Meta-X) @item Expert/Nohelp Toggle (Meta-X)
toggles the -x (--nohelp) command line flag. toggles the -x (@code{--nohelp}) command line flag.
@item Suspend Toggle (Meta-Z) @item Suspend Toggle (Meta-Z)
toggles the -z (--suspend) command line flag. toggles the -z (@code{--suspend}) command line flag.
@item Open Previous File Toggle (Meta-<) @item Open Previous File Toggle (Meta-<)
changes buffer to previously loaded file. changes buffer to previously loaded file.
...@@ -366,9 +370,9 @@ changes buffer to previously loaded file. ...@@ -366,9 +370,9 @@ changes buffer to previously loaded file.
@item Open Next File Toggle (Meta->) @item Open Next File Toggle (Meta->)
changes buffer to next loaded file. changes buffer to next loaded file.
@end table @end table
@node The File Browser, Pico Compatibility, Feature Toggles, Top @node The File Browser, Pico Compatibility, Feature Toggles, Top
@chapter The File Browser @chapter The File Browser
...@@ -376,8 +380,8 @@ When reading or writing files, pressing ^T will invoke the file browser. ...@@ -376,8 +380,8 @@ When reading or writing files, pressing ^T will invoke the file browser.
Here, one can navigate directories in a graphical manner in order to Here, one can navigate directories in a graphical manner in order to
find the desired file. find the desired file.
Basic movement in the file browser is accomplished with he arrow keys 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 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, 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 If the object is a file, this filename and path are copied to the
...@@ -391,23 +395,27 @@ differences apply to the default mode and Pico Compatibility mode: ...@@ -391,23 +395,27 @@ differences apply to the default mode and Pico Compatibility mode:
@table @code @table @code
@item Displayed Shortcuts @item Displayed Shortcuts
By default, the following shortcuts are displayed in the Shortcut Lists: By default, the following shortcuts are displayed in the Shortcut List:
^G ^O ^\ ^Y ^K ^C@* @multitable @columnfractions .1 .1 .1 .1 .1 .1
^X ^R ^W ^V ^U ^T @item ^G @tab ^O @tab ^\ @tab ^Y @tab ^K @tab ^C
@item ^X @tab ^R @tab ^W @tab ^V @tab ^U @tab ^T
@end multitable
Related functions are listed above or below each other by default. The Related functions are listed above or below each other by default. The
Justify function is not listed, instead the "Replace" function is Justify function is not listed, instead the ``Replace'' function is
displayed. Also, he "Read File" and "WriteOut" functions are aligned for displayed. Also, the ``Read File'' and ``WriteOut'' functions are aligned
consistency. for consistency.
In Pico Compatibility mode, the default Pico shortcuts are displayed: In Pico Compatibility mode, the default Pico shortcuts are displayed:
^G ^O ^R ^Y ^K ^C@* @multitable @columnfractions .1 .1 .1 .1 .1 .1
^X ^J ^W ^V ^U ^T @item ^G @tab ^O @tab ^R @tab ^Y @tab ^K @tab ^C
@item ^X @tab ^J @tab ^W @tab ^V @tab ^U @tab ^T
@end multitable
@item Previous String Text @item Previous String Text
By default, previously entered string for a function (search string, By default, the previously entered string for a function (search string,
file name) will be placed on the statusbar, and is editable. This is file name) will be placed on the statusbar, and is editable. This is
done so there is consistency across all functions. For example: even if done so there is consistency across all functions. For example: even if
there is a previous replace string, it can always be deleted if one there is a previous replace string, it can always be deleted if one
...@@ -434,11 +442,13 @@ to force these functions to behave in the Pico fashion. ...@@ -434,11 +442,13 @@ to force these functions to behave in the Pico fashion.
Building @code{nano} from source is fairly straightforward if you are familiar Building @code{nano} from source is fairly straightforward if you are familiar
with compiling programs with autoconf support: with compiling programs with autoconf support:
tar xvfz nano-x.y.z.tar.gz (where x.y.z is the version of @code{nano}) @itemize @bullet
cd nano-x.y.z/ @item tar xvfz nano-x.y.z.tar.gz (where x.y.z is the version of nano)
./configure @item cd nano-x.y.z/
make @item ./configure
make install @item make
@item make install
@end itemize
if you are looking to optimize @code{nano} for size, you may want to if you are looking to optimize @code{nano} for size, you may want to
consider the following command line options: consider the following command line options:
...@@ -453,34 +463,34 @@ Disable the tab completion code when reading or writing files. ...@@ -453,34 +463,34 @@ Disable the tab completion code when reading or writing files.
Disable the justify (^J)/unjustify (^U) functions in the editor. Disable the justify (^J)/unjustify (^U) functions in the editor.
@item --disable-speller @item --disable-speller
Disables spell checker ability. Disable spell checker ability.
@item --disable-help @item --disable-help
Disables the help function (^G). Disabling this option makes the binary Disable the help function (^G). Disabling this option makes the binary
much smaller, but makes it difficult for new users to learn more than much smaller, but makes it difficult for new users to learn more than
very basic things about using the editor. very basic things about using the editor.
@item --disable-browser @item --disable-browser
Disables the mini file browser (^O) when reading or writing files. Disable the mini file browser (^T) when reading or writing files.
@item --disable-mouse
Disable all mouse functionality. This also disables the -m command line
flag, which enables the mouse functions.
@item --disable-operatingdir
Disable setting the operating directory. This also disables the -o
command line flag.
@item --enable-tiny @item --enable-tiny
This options disables all the above. It also disables some of the larger This option disables all the above. It also disables some of the larger
internals of the editor, like the marker code (^^) and the cut to line internals of the editor, like the marker code (^^) and the cut to line
(-k) option which it depends on to work properly. It also disables the (-k) option, which depends on the marker code to work properly. It also
function toggles and mouse support. disables the function toggles.
@item --disable-wrapping @item --disable-wrapping
Disables all word wrapping in the editor. This also eliminates the -w Disable all word wrapping in the editor. This also eliminates the -w
command line flag, as nonwrapping is then the default behavior. command line flag, as nonwrapping is then the default behavior.
@item --disable-mouse
Disables all mouse functionality. This also disables the -m command
line flag which enables the mouse functions.
@item --disable-operatingdir
Disables setting of operating directory. This also disables the -o
command line flag.
@item --disable-nls @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. @code{nano} translations unusable.
......
...@@ -81,8 +81,9 @@ ...@@ -81,8 +81,9 @@
# syntax "short description" ["filename regex" ...] # syntax "short description" ["filename regex" ...]
# color foreground,background "regex" ["regex"...] # color foreground,background "regex" ["regex"...]
# #
# Legal colors are: white, black, red, blue, green, yellow, purple, cyan # Legal colors are: white, black, red, blue, green, yellow, purple,
# You may use the prefix "bright" to mean a stronger color highlight # cyan. You may use the prefix "bright" to mean a stronger color
# highlight.
# #
# To use multi-line regexes use the start="regex" end="regex" format. # To use multi-line regexes use the start="regex" end="regex" format.
# #
...@@ -99,8 +100,9 @@ ...@@ -99,8 +100,9 @@
# color brightcyan "#elif" "#else" "#if" # color brightcyan "#elif" "#else" "#if"
# You will in general want your comments and strings to come last, # You will in general want your comments and strings to come last,
# because syntax highlighting rules will be applied in the order they are # because syntax highlighting rules will be applied in the order they
# read in # are read in. Note that quotes in regexes should not be escaped (use "
# instead of \").
# color brightyellow "<[^= ]*>" ""(\\.|[^\"])*"" # color brightyellow "<[^= ]*>" ""(\\.|[^\"])*""
# color brightyellow start=""(\\.|[^\"])*\\( | )*$" end="^(\\.|[^\"])*"" # color brightyellow start=""(\\.|[^\"])*\\( | )*$" end="^(\\.|[^\"])*""
......
...@@ -834,7 +834,7 @@ int do_find_bracket(void) ...@@ -834,7 +834,7 @@ int do_find_bracket(void)
flagsave = flags; flagsave = flags;
SET(USE_REGEXP); SET(USE_REGEXP);
/* apparent near redundancy with regexp_pat[] here is needed, [][] works, [[]] doesn't */ /* apparent near redundancy with regexp_pat[] here is needed, [][] works, [[]] doesn't */
if (offset < (strlen(brackets) / 2)) { /* on a left bracket */ if (offset < (strlen(brackets) / 2)) { /* on a left bracket */
regexp_pat[1] = wanted_ch; regexp_pat[1] = wanted_ch;
...@@ -852,7 +852,7 @@ int do_find_bracket(void) ...@@ -852,7 +852,7 @@ int do_find_bracket(void)
search_last_line = 0; search_last_line = 0;
if (findnextstr(1, 1, current, current_x, regexp_pat)) { if (findnextstr(1, 1, current, current_x, regexp_pat)) {
have_past_editbuff |= past_editbuff; have_past_editbuff |= past_editbuff;
if (current->data[current_x] == ch_under_cursor) /* found identical bracket */ if (current->data[current_x] == ch_under_cursor) /* found identical bracket */
count++; count++;
else { /* found complementary bracket */ else { /* found complementary bracket */
if (!(--count)) { if (!(--count)) {
...@@ -862,7 +862,7 @@ int do_find_bracket(void) ...@@ -862,7 +862,7 @@ int do_find_bracket(void)
update_line(current, current_x); update_line(current, current_x);
placewewant = xplustabs(); placewewant = xplustabs();
reset_cursor(); reset_cursor();
break ; break;
} }
} }
} else { /* didn't find either left or right bracket */ } else { /* didn't find either left or right bracket */
......
...@@ -1659,7 +1659,7 @@ void dump_buffer_reverse(void) { ...@@ -1659,7 +1659,7 @@ void dump_buffer_reverse(void) {
#endif /* DEBUG */ #endif /* DEBUG */
#ifdef NANO_EXTRA #ifdef NANO_EXTRA
#define CREDIT_LEN 52 #define CREDIT_LEN 53
#define XLCREDIT_LEN 8 #define XLCREDIT_LEN 8
void do_credits(void) void do_credits(void)
...@@ -1681,6 +1681,7 @@ void do_credits(void) ...@@ -1681,6 +1681,7 @@ void do_credits(void)
"Rob Siemborski", "Rob Siemborski",
"Rocco Corsi", "Rocco Corsi",
"David Lawrence Ramsey", "David Lawrence Ramsey",
"David Benbennick",
"Ken Tyler", "Ken Tyler",
"Sven Guckes", "Sven Guckes",
"Florian Knig", "Florian Knig",
...@@ -1715,7 +1716,7 @@ void do_credits(void) ...@@ -1715,7 +1716,7 @@ void do_credits(void)
"", "", "", "", "", "", "", "",
"(c) 1999-2002 Chris Allegretta", "(c) 1999-2002 Chris Allegretta",
"", "", "", "", "", "", "", "",
"www.nano-editor.org" "http://www.nano-editor.org/"
}; };
xlcredits[0] = _("The nano text editor"); xlcredits[0] = _("The nano text editor");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment