diff options
| -rw-r--r-- | CHANGES | 21 | ||||
| -rw-r--r-- | WWW/Library/Implementation/tcp.h | 128 | ||||
| -rw-r--r-- | aclocal.m4 | 23 | ||||
| -rw-r--r-- | config.hin | 3 | ||||
| -rwxr-xr-x | configure | 45 | ||||
| -rw-r--r-- | configure.in | 5 | ||||
| -rw-r--r-- | lynx.cfg | 18 | ||||
| -rw-r--r-- | lynx_help/keystrokes/option_help.html | 589 | ||||
| -rw-r--r-- | src/HTAlert.c | 4 | ||||
| -rw-r--r-- | src/LYCurses.h | 7 | ||||
| -rw-r--r-- | src/LYDownload.c | 11 | ||||
| -rw-r--r-- | src/LYHistory.c | 14 | ||||
| -rw-r--r-- | src/LYMain.c | 4 | ||||
| -rw-r--r-- | src/LYMainLoop.c | 13 | ||||
| -rw-r--r-- | src/LYUtils.c | 33 | ||||
| -rw-r--r-- | userdefs.h | 9 |
16 files changed, 531 insertions, 396 deletions
@@ -1,6 +1,25 @@ Changes since Lynx 2.8 release ================================================================================ +1998-10-04 (2.8.1pre.7) +* add special-case CF_TERMIOS_AND_CURSES configure macro (fixes problem reported + by Philippe De Muyter) - TD +* update/reorganize option_help.html (Philip Webb). +* Restore newline position when return from the Print menu or follow a link + from History page (was broken for partial display mode only): LYPop() and + LYPop_num now reinitialize Newline_partial if it happens on getfile stage. + Also remove changes from 1998-06-11 (case LYK_DOWNLOAD) since this is now + protected by HText_new() which never starts. - LP +* tweak suggested filename for download menu: now it we have URL + terminated with "/" (e.g. a directory or possibly root) do one more try - + remove terminating "/" - LP +* download menu: do not show "Suggested file name" when "save to disk disabled" + (requested by HN) - LP +* more tweaks on LYshow_kb_rate - LP +* move fallback definitions for POSIX S_ISLNK, etc., to allow build with + VAX C (reported by Tony Bolton) - TD +* add parentheses to eval-expression in CF_MAKE_INCLUDE configure test to + accommodate bash2 (Tadayoshi Okuma <tad@pht.co.jp>) 1998-10-01 (2.8.1pre.6) * add EMX to special cases for SetOutputMode, to force stdout to O_BINARY mode so that downloading binary files will not corrupt them (reported by Ilya @@ -45,8 +64,6 @@ Changes since Lynx 2.8 release 1998-09-28 (2.8.1pre.4) * tentative fix for HPUX sed problems (reported by jones.peter@uqam.ca) - TD * update lynx.man and lynx.hlp to reflect new command-line options - TD -* add PARTIAL_MIN_LINES switch in lynx.cfg to customize incremental rendering - with smaller chunks (requested by Eric <erbrun@bellatlantic.net>) - LP * minor documentation fix - LP * miscellaneous fixes for build on VMS (reported by Tony Bolton) - TD * tweak 'const' assignment for VMS (in LYReadCFG.c and LYPrint.c) - LP diff --git a/WWW/Library/Implementation/tcp.h b/WWW/Library/Implementation/tcp.h index 4afefa59..3ebff46f 100644 --- a/WWW/Library/Implementation/tcp.h +++ b/WWW/Library/Implementation/tcp.h @@ -514,70 +514,6 @@ Regular BSD unix versions #include <sys/param.h> #include <sys/file.h> /* For open() etc */ -#ifndef S_ISLNK -#define S_ISLNK(m) (((m) & S_IFMT) == S_IFLNK) -#endif /* S_ISLNK */ - -#ifndef S_ISDIR -#define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR) -#endif /* S_ISDIR */ - -#ifndef S_ISREG -#define S_ISREG(m) (((m) & S_IFMT) == S_IFREG) -#endif /* S_ISREG */ - -#ifndef S_ISUID -#define S_ISUID 0004000 -#endif -#ifndef S_ISGID -#define S_ISGID 0002000 -#endif -#ifndef S_ISVTX -#define S_ISVTX 0001000 -#endif - -#ifndef S_IRWXU -#define S_IRWXU 00700 -#endif - -#ifndef S_IRUSR -#define S_IRUSR 00400 -#endif -#ifndef S_IWUSR -#define S_IWUSR 00200 -#endif -#ifndef S_IXUSR -#define S_IXUSR 00100 -#endif - -#ifndef S_IRWXG -#define S_IRWXG 00070 -#endif - -#ifndef S_IRGRP -#define S_IRGRP 00040 -#endif -#ifndef S_IWGRP -#define S_IWGRP 00020 -#endif -#ifndef S_IXGRP -#define S_IXGRP 00010 -#endif - -#ifndef S_IRWXO -#define S_IRWXO 00007 -#endif - -#ifndef S_IROTH -#define S_IROTH 00004 -#endif -#ifndef S_IWOTH -#define S_IWOTH 00002 -#endif -#ifndef S_IXOTH -#define S_IXOTH 00001 -#endif - #if defined(NeXT) || defined(sony_news) #ifndef mode_t typedef unsigned short mode_t; @@ -673,6 +609,70 @@ Defaults #include <netdb.h> #endif /* TCP includes */ +#ifndef S_ISLNK +#define S_ISLNK(m) (((m) & S_IFMT) == S_IFLNK) +#endif /* S_ISLNK */ + +#ifndef S_ISDIR +#define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR) +#endif /* S_ISDIR */ + +#ifndef S_ISREG +#define S_ISREG(m) (((m) & S_IFMT) == S_IFREG) +#endif /* S_ISREG */ + +#ifndef S_ISUID +#define S_ISUID 0004000 +#endif +#ifndef S_ISGID +#define S_ISGID 0002000 +#endif +#ifndef S_ISVTX +#define S_ISVTX 0001000 +#endif + +#ifndef S_IRWXU +#define S_IRWXU 00700 +#endif + +#ifndef S_IRUSR +#define S_IRUSR 00400 +#endif +#ifndef S_IWUSR +#define S_IWUSR 00200 +#endif +#ifndef S_IXUSR +#define S_IXUSR 00100 +#endif + +#ifndef S_IRWXG +#define S_IRWXG 00070 +#endif + +#ifndef S_IRGRP +#define S_IRGRP 00040 +#endif +#ifndef S_IWGRP +#define S_IWGRP 00020 +#endif +#ifndef S_IXGRP +#define S_IXGRP 00010 +#endif + +#ifndef S_IRWXO +#define S_IRWXO 00007 +#endif + +#ifndef S_IROTH +#define S_IROTH 00004 +#endif +#ifndef S_IWOTH +#define S_IWOTH 00002 +#endif +#ifndef S_IXOTH +#define S_IXOTH 00001 +#endif + /* ROUGH ESTIMATE OF MAX PATH LENGTH @@ -791,7 +791,7 @@ all : @echo 'cf_make_include=\$(RESULT)' CF_EOF cf_make_include="" - eval `cd $cf_dir && ${MAKE-make} 2>&AC_FD_CC | grep cf_make_include=OK` + eval `(cd $cf_dir && ${MAKE-make}) 2>&AC_FD_CC | grep cf_make_include=OK` if test -n "$cf_make_include"; then make_include_left="$cf_include" make_include_quote="$cf_quote" @@ -1466,6 +1466,27 @@ if test "$cf_cv_lib_termcap" = none; then fi ])dnl dnl --------------------------------------------------------------------------- +dnl Check if including termio.h with <curses.h> dies like on sysv68 +dnl FIXME: this is too Lynx-specific +AC_DEFUN([CF_TERMIO_AND_CURSES], +[ +AC_CACHE_CHECK(if we can include termio.h with curses,cf_cv_termio_and_curses,[ + cf_save_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -DHAVE_CONFIG_H -I. -I${srcdir-.} -I${srcdir-.}/src -I${srcdir-.}/WWW/Library/Implementation" + touch lynx_cfg.h + AC_TRY_COMPILE([ +#include <$1> +#include <termio.h>], + [putchar(0x0a)], + [cf_cv_termio_and_curses=yes], + [cf_cv_termio_and_curses=no]) + CFLAGS="$cf_save_CFLAGS" + rm -f lynx_cfg.h +]) + +test $cf_cv_termio_and_curses = no && AC_DEFINE(TERMIO_AND_CURSES) +])dnl +dnl --------------------------------------------------------------------------- dnl Check if including both termio.h and termios.h die like on DG.UX AC_DEFUN([CF_TERMIO_AND_TERMIOS], [ @@ -96,7 +96,8 @@ #undef SYSTEM_MAIL /* CF_DEFINE_PROG */ #undef SYSTEM_MAIL_FLAGS /* defined by CF_SYSTEM_MAIL_FLAGS */ #undef TAR_PATH /* CF_PATH_PROG(tar) */ -#undef TERMIO_AND_TERMIOS /* termio.h and termios.h combo bug */ +#undef TERMIO_AND_CURSES /* CF_TERMIO_AND_CURSES workaround */ +#undef TERMIO_AND_TERMIOS /* CF_TERMIO_AND_TERMIOS workaround */ #undef TOUCH_PATH /* CF_PATH_PROG(touch) */ #undef ULTRIX /* config.sub */ #undef UNCOMPRESS_PATH /* CF_PATH_PROG(gunzip) */ @@ -929,7 +929,7 @@ all : @echo 'cf_make_include=\$(RESULT)' CF_EOF cf_make_include="" - eval `cd $cf_dir && ${MAKE-make} 2>&5 | grep cf_make_include=OK` + eval `(cd $cf_dir && ${MAKE-make}) 2>&5 | grep cf_make_include=OK` if test -n "$cf_make_include"; then make_include_left="$cf_include" make_include_quote="$cf_quote" @@ -8521,6 +8521,49 @@ fi echo "$ac_t""$enableval" 1>&6 + +echo $ac_n "checking if we can include termio.h with curses""... $ac_c" 1>&6 +echo "configure:8527: checking if we can include termio.h with curses" >&5 +if eval "test \"`echo '$''{'cf_cv_termio_and_curses'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +else + + cf_save_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -DHAVE_CONFIG_H -I. -I${srcdir-.} -I${srcdir-.}/src -I${srcdir-.}/WWW/Library/Implementation" + touch lynx_cfg.h + cat > conftest.$ac_ext <<EOF +#line 8536 "configure" +#include "confdefs.h" + +#include <LYCurses.h> +#include <termio.h> +int main() { +putchar(0x0a) +; return 0; } +EOF +if { (eval echo configure:8545: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + cf_cv_termio_and_curses=yes +else + echo "configure: failed program was:" >&5 + cat conftest.$ac_ext >&5 + rm -rf conftest* + cf_cv_termio_and_curses=no +fi +rm -f conftest* + CFLAGS="$cf_save_CFLAGS" + rm -f lynx_cfg.h + +fi + +echo "$ac_t""$cf_cv_termio_and_curses" 1>&6 + +test $cf_cv_termio_and_curses = no && cat >> confdefs.h <<\EOF +#define TERMIO_AND_CURSES 1 +EOF + + + ### Finally, build config.h and the makefiles CFLAGS="$CFLAGS $EXTRA_CFLAGS" srcdir="$srcdir" diff --git a/configure.in b/configure.in index ebe613dd..c0dc030b 100644 --- a/configure.in +++ b/configure.in @@ -693,6 +693,11 @@ CF_ARG_DISABLE(parent-dir-refs, [AC_DEFINE(NO_PARENT_DIR_REFERENCE)]) AC_MSG_RESULT($enableval) +dnl -------------------------------------------------------------------------- +dnl Test features that rely on configure-definitions +dnl -------------------------------------------------------------------------- +CF_TERMIO_AND_CURSES(LYCurses.h) + ### Finally, build config.h and the makefiles CFLAGS="$CFLAGS $EXTRA_CFLAGS" srcdir="$srcdir" @@ -256,6 +256,9 @@ DEFAULT_INDEX_FILE:http://www.ncsa.uiuc.edu/SDG/Software/Mosaic/MetaIndex.html # RFC 1345 Mnemonic mnemonic # Transparent x-transparent # +# The value should be the MIME name of a character set recognized by +# Lynx (case insensitive). +# #CHARACTER_SET:iso-8859-1 # ASSUME_CHARSET changes the handling of documents which do not @@ -268,8 +271,6 @@ DEFAULT_INDEX_FILE:http://www.ncsa.uiuc.edu/SDG/Software/Mosaic/MetaIndex.html # Character Set. # ASSUME_CHARSET can also be changed via the 'o'ptions menu but will # not be saved as permanent value in user's .lynxrc file to avoid more chaos. -# The value should be the MIME name of a character set recognized by -# Lynx (case insensitive). # #ASSUME_CHARSET:iso-8859-1 @@ -277,8 +278,8 @@ DEFAULT_INDEX_FILE:http://www.ncsa.uiuc.edu/SDG/Software/Mosaic/MetaIndex.html # files. If no setting is given here or by an -assume_local_charset # command line option, the value for ASSUME_CHARSET or -assume_charset # is used. It works for both text/plain and text/html files. -# This option may interfere with "raw mode" toggling when local files -# are viewed (it is "stronger" than "assume_charset" or the effective change +# This option will ignore "raw mode" toggling when local files are viewed +# (it is "stronger" than "assume_charset" or the effective change # of the charset assumption caused by changing "raw mode"), # so only use when necessary. # @@ -392,15 +393,12 @@ DEFAULT_INDEX_FILE:http://www.ncsa.uiuc.edu/SDG/Software/Mosaic/MetaIndex.html # Display partial pages while downloading #PARTIAL:TRUE + # Set the threshold # of lines Lynx must render before it -# redraws the screen. Anything < 0 implies use the screen -# size. +# redraws the screen in PARTIAL mode. Anything < 0 implies +# use the screen size. #PARTIAL_THRES:-1 -# Minimum lines amount for first redisplay in PARTIAL mode -# (0 - wait for complete screen by default). -#PARTIAL_MIN_LINES:0 - # While getting large files, Lynx shows the approximate rate of # transfer. Set this to change the units shown (true for KB/sec, # and false for bytes/sec). diff --git a/lynx_help/keystrokes/option_help.html b/lynx_help/keystrokes/option_help.html index 69d7c8c9..63862ca2 100644 --- a/lynx_help/keystrokes/option_help.html +++ b/lynx_help/keystrokes/option_help.html @@ -5,288 +5,311 @@ <LINK rev="made" href="mailto:lynx-dev@sig.net"> </HEAD> <BODY> -<h1>+++ Options Screen Help +++</h1> -<PRE> - The Options Screen allows you to set and - modify many of Lynx's features. The following - options may be set. - - Editor - If non-empty it defines the editor to spawn - when editing a local file or sending mail. - Any valid text editor may be entered here. - - DISPLAY variable - If non-empty it specifies your <A HREF="xterm_help.html">X terminal</A> - display address. - - Multi-bookmarks - When OFF, the default bookmark file is used - for the 'v'iew bookmarks and 'a'dd bookmark - link commands. If set to STANDARD, a menu - of available bookmarks always is invoked - when you seek to view a bookmark file or add - a link, and you select the bookmark file by - its letter token in that menu. If set to - ADVANCED, you instead are prompted for the - letter of the desired bookmark file, but can - enter '=' to invoke the STANDARD selection - menu, or RETURN for the default bookmark file. - - Bookmark file - If non-empty and multi-bookmarks is OFF, it - specifies your default '<A HREF="bookmark_help.html">Bookmark file</A>'. - If multi-bookmarks is STANDARD or ADVANCED, - entering 'B' will invoke a menu in which you - can specify the filepaths and descriptions - of up to 26 bookmark files. The filepaths - must be from your home directory, and begin - with dot-slash (./) if subdirectories are - included (e.g, ./BM/lynx_bookmarks.html). - Lynx will create bookmark files when you - first 'a'dd a link, but any subdirectories - in the filepath must already exist. - - FTP sort criteria - This option allows you to specify how files - will be sorted within FTP listings. The - current options include "By Filename", - "By Size", "By Type", and "By Date". - - Personal Mail - You may set your mail address here so that - Address when mailing messages to other people or - mailing files to yourself, your email address - can be automatically filled in. Your email - address will also be sent to HTTP servers in - a from: field. - - Searching type - If set to 'case sensitive', user searches - invoked by the '/' command will be case - sensitive substring searches. The - default is 'Case Insensitive' substring - searches - - Preferred Document - The language you prefer if multi-language files - Language are available from servers. Use RFC 1766 tags, - e.g., en for English, fr for French, etc. Can be - a comma-separated list, which may be interpreted - by servers as descending order of preferences. - You can also make your order of preference explicit - by using q factors as defined by the HTTP protocol, - for servers which understand it, for example: - <kbd>da, en-gb;q=0.8, en;q=0.7</kbd> - - Preferred Document - The character set you prefer if sets in addition - Charset to ISO-8859-1 and US-ASCII are available from - servers. Use MIME notation (e.g., ISO-8859-2) - and do not include ISO-8859-1 or US-ASCII, since - those values are always assumed by default. Can - be a comma-separated list, which may be interpreted - by servers as descending order of preferences. - You can also make your order of preference explicit - by using q factors as defined by the HTTP protocol, - for servers which understand it, for example: - <kbd>iso-8859-5, utf-8;q=0.8</kbd> - - Display Character - This option allows you to set up the default - set character set for your specific terminal. The - display character set provides a mapping from the - character encodings of viewed documents and from - HTML entities into viewable characters. It should - be set according to your terminal's character set - so that characters other than 7-bit ASCII can be - displayed correctly, using approximations if - necessary. You must have the selected character set - installed on your terminal. (Since Lynx now supports - a wide range of platforms it may be useful to note - that cpXXX codepages are used within IBM PC - computers, and windows-xxxx within native MS-Windows - applications). - - Raw 8-bit or CJK - This option set automatically but can be toggled - mode manually in certain special cases: - it toggles whether 8-bit characters are assumed to - correspond with the display character set and - therefore are processed without translation via the - chartrans conversion tables. ON by default when the - display character set is one of the Asian (CJK) - sets and the 8-bit characters are Kanji multibytes. - OFF for the other display character sets, but can - be turned ON when the document's charset is unknown - (e.g., is not ISO-8859-1 and no charset parameter - was specified in a reply header from an HTTP server - to indicate what it is) but you have no better idea - than viewing it as from display character set (see - also 'assumed document character set' for best - choice). Should be OFF when an Asian (CJK) set is - selected but the document is ISO-8859-1 or another - 'assumed document character set'. The setting also - can be toggled via the RAW_TOGGLE command, normally - mapped to '@', and at startup via the -raw switch. - - Assumed document - This option changes the handling of documents - character set which do not explicitly specify a charset. - Normally Lynx assumes that 8-bit characters in - those documents are encoded according to iso-8859-1 - (the official default for the HTTP protocol). - Unfortunately, many non-English web pages "forget" - to include proper charset info; this option helps - you to browse those broken pages if you know by - some means what the charset is. When the value - given here or by an -assume_charset command line - flag is in effect, Lynx will treat documents as if - they were encoded accordingly. This option active - when 'Raw 8-bit or CJK Mode' is OFF. - - Show color - This option will be present if color support is - available. If set to ON or ALWAYS, color mode will - be forced on if possible. If (n)curses color - support is available but cannot be used for the - current terminal type, selecting ON is rejected - with a message. If set to OFF or NEVER, color mode - will be turned off. - ALWAYS and NEVER are not offered in anonymous - accounts. If saved to a '.lynxrc' file in - non-anonymous accounts, ALWAYS will cause Lynx to - set color mode on at startup if supported. If Lynx - is built with the slang library, this is equivalent - to having included the -color command line switch - or having the COLORTERM environment variable - set. If color support is provided by curses or - ncurses, this is equivalent to the default behavior - of using color when the terminal type supports it. - If (n)curses color support is available but cannot - be used for the current terminal type, the - preference can still be saved but will have no - effect. - A saved value of NEVER will cause Lynx to assume a - monochrome terminal at startup. It is similar to - the -nocolor switch, but (when the slang library is - used) can be overridden with the -color switch. - If the setting is OFF or ON when the current - options are saved to a '.lynxrc' file, the default - startup behavior is retained, such that color mode - will be turned on at startup only if the terminal - info indicates that you have a color-capable - terminal, or (when the slang library is used) if - forced on via the -color switch or COLORTERM - variable. This default behavior always is used in - anonymous accounts, or if the 'option'_save - restriction is set explicitly. If for any reason - the startup color mode is incorrect for your - terminal, set it appropriately on or off via this - option. - - VI keys - If set to 'ON' then the lowercase h, j, k, and l, - keys will be mapped to left-arrow, down-arrow, - up-arrow, and right-arrow, respectively. The - uppercase H, J, K, and L keys remain mapped to - their configured bindings (normally HELP, JUMP, - KEYMAP, and LIST, respectively). - - Emacs keys - If set to 'ON' then the CTRL-P, CTRL-N, CTRL-F, - and CTRL-B keys will be mapped to up-arrow, - down-arrow, right-arrow, and left-arrow, - respectively. Otherwise, they remain mapped - to their configured bindings (normally UP_TWO - lines, DOWN_TWO lines, NEXT_PAGE, and PREV_PAGE, - respectively). - - Show dot files - If display/creation of hidden (dot) - files/directories is enabled, you can turn - the feature on or off via this setting. - - Popups for select - Lynx normally uses a popup window for the - fields OPTIONs in form SELECT fields when the field - does not have the MULTIPLE attribute specified, - and thus only one OPTION can be selected. The - use of popup windows can be disabled by changing - this setting to OFF, in which case the OPTIONs - will be rendered as a list of radio buttons. - Note that if the SELECT field does have the - MULTIPLE attribute specified, the OPTIONs always - are rendered as a list of checkboxes. - - Show cursor for - Lynx normally hides the cursor by positioning it - current link or to the right and if possible the very bottom of - option the screen, so that the current link or OPTION - is indicated solely by its highlighting or color. - If show cursor is set to ON, the cursor will be - positioned at the left of the current link or - OPTION. This is helpful when Lynx is being used - with a speech or braille interface. It also is - useful for sighted users when the terminal cannot - distinguish the character attributes used to - distinguish the current link or OPTION from the - others in the screen display. - - Keypad mode - This option gives the choice between navigating - with the keypad (as arrows; see Lynx Navigation) - and having every link numbered (numbered links) - so that the links may be selected by numbers - instead of moving to them with the arrow keys. - - Line edit style - This option allows you to set alternate key - bindings for the built-in line editor, if your - system administrator has installed alternates. - Otherwise, Lynx uses the <A HREF="edit_help.html">Default Binding</A>. - - List directory - Applies to Directory Editing. Files and - style directories can be presented in the following - ways: - Mixed style - Files and directories are listed together in - alphabetical order. - Directories first - Files and directories are separated into two - alphabetical lists. Directories are listed - first. - Files first - Files and directories are separated into two - alphabetical lists. Files are listed first. - - User Mode - Novice - Shows two extra lines of help at the bottom - of the screen for beginners - Intermediate (normal mode) - The "normal" statusline messages appear. - Advanced - The URL is shown on the statusline. - - Verbose Images - Controls whether or not Lynx replaces the [LINK], - [INLINE] and [IMAGE] comments (for images without - ALT) with filenames of these images. This is - extremely useful because now we can determine - immediately what images are just decorations - (button.gif, line.gif) and what images are - important. - - User Agent - The header string which Lynx sends to servers - to indicate the User-Agent is displayed here. - Changes may be disallowed via the -restrictions - switch. Otherwise, the header can be changed - temporarily to a string such as L_y_n_x/2.8.1 for - access to sites which discriminate against Lynx - based on checks for the presence of "Lynx" in the - header. If changed during a Lynx session, the - default User-Agent header can be restored by - deleting the modified string in the Options Menu. - Whenever the User-Agent header is changed, the - current document is reloaded, with the no-cache - flags set, on exit from the Options Menu. Changes - of the header are not saved in the RC file. - NOTE that Netscape Communications Corp. has - claimed that false transmissions of "Mozilla" as - the User-Agent are a copyright infringement, which - will be prosecuted. DO NOT misrepresent Lynx as - Mozilla. The Options Menu issues a warning about - possible copyright infringement whenever the header - is changed to one which does not include "Lynx" or - "lynx". - - Local execution - If set to 'ALWAYS ON', Lynx will locally execute - links commands contained inside of any links. This - can be HIGHLY DANGEROUS so it is recommended - that they remain 'ALWAYS OFF' or 'FOR LOCAL - FILES ONLY' unless otherwise set by your system - administrator. This option may not be available - on most versions of Lynx. - -</PRE> +<h1>OPTIONS SCREEN HELP</h1> + +The Options Screen allows you to set and modify many Lynx features.<BR> +Note: some options appear on the screen only if they have been +compiled in or chosen in `lynx.cfg':<P> + +<UL> +<LI>Personal Preferences +<UL> +<LI>-- Cookies : no help given -- +<LI><A HREF="#ED">Editor</A> +<LI><A HREF="#EM">Emacs keys</A> +<LI><A HREF="#KM">Keypad mode</A> +<LI><A HREF="#PM">Personal Mail Address</A> +<LI><A HREF="#PU">Pop-ups for select fields</A> +<LI><A HREF="#ST">Searching type</A> +<LI><A HREF="#SC">Show color</A> +<LI><A HREF="#CL">Show cursor for current link or option</A> +<LI><A HREF="#UM">User Mode</A> +<LI><A HREF="#VB">Verbose Images</A> +<LI><A HREF="#VI">VI keys</A> +<LI><A HREF="#DV">X DISPLAY variable</A></UL> +<LI>Bookmark Options +<UL> +<LI><A HREF="#MB">Multi-bookmarks</A> +<LI><A HREF="#BF">Bookmark file</A></UL> +<LI>Character Set Options +<UL> +<LI><A HREF="#AD">Assumed document character set</A> +<LI><A HREF="#DC">Display Character set</A> +<LI><A HREF="#JK">Raw 8-bit or CJK mode</A></UL> +<LI>File Management Options +<UL> +<LI><A HREF="#FT">FTP sort criteria</A> +<LI><A HREF="#LD">Local directory sort criteria</A> +<LI><A HREF="#DF">Show dot files</A> +</UL> +<LI>Headers transferred to remote server +<UL> +<LI><A HREF="#PC">Preferred Document Charset</A> +<LI><A HREF="#PL">Preferred Document Language</A> +<LI><A HREF="#UA">User Agent</A> +</UL> +<LI>-- not in Options Form -- +<UL> +<LI><A HREF="#LE">Line edit style</A> +<LI><A HREF="#LL">Local execution links</A></UL> +</UL> + +<H1><A NAME="ED">Editor</A></H1> + +If non-empty, it defines the editor to spawn when editing a local file +or sending mail. Any valid text editor may be entered here. + +<H1><A NAME="EM">Emacs keys</A></H1> + +If set to 'ON' then the CTRL-P, CTRL-N, CTRL-F and CTRL-B keys will be mapped +to up-arrow, down-arrow, right-arrow and left-arrow respectively. Otherwise, +they remain mapped to their configured bindings (normally UP_TWO lines, +DOWN_TWO lines, NEXT_PAGE and PREV_PAGE respectively). + +<H1><A NAME="KM">Keypad mode</A></H1> + +This gives the choice between navigating with the keypad (as arrows; +see Lynx Navigation) and having every link numbered (numbered links) +so that the links may be selected by numbers instead of moving to them +with the arrow keys. You can also number form fields. + +<H1><A NAME="PM">Personal Mail Address</A></H1> + +You may set your mail address here so that when mailing messages +to other people or mailing files to yourself, your email address can be +automatically filled in. Your email address will also be sent +to HTTP servers in a `from:' field. + +<H1><A NAME="PU">Pop-ups for select fields</A></H1> + +Lynx normally uses a pop-up window for the OPTIONs in form SELECT fields +when the field does not have the MULTIPLE attribute specified, and thus +only one OPTION can be selected. The use of pop-up windows can be disabled +by changing this setting to OFF, in which case the OPTIONs will be rendered +as a list of radio buttons. Note that if the SELECT field does have +the MULTIPLE attribute specified, the OPTIONs always are rendered +as a list of checkboxes. + +<H1><A NAME="ST">Searching type</A></H1> + +If set to 'case sensitive', user searches invoked by '/' will be +case-sensitive substring searches. Default is 'Case Insensitive'. + +<H1><A NAME="SC">Show color</A></H1> + +This will be present if color support is available. +<ul> +<li>If set to ON or ALWAYS, +color mode will be forced on if possible. If (n)curses color support +is available but cannot be used for the current terminal type, selecting ON +is rejected with a message. +<li>If set to OFF or NEVER, color mode will be +turned off. +<li>ALWAYS and NEVER are not offered in anonymous accounts. +If saved to a '.lynxrc' file in non-anonymous accounts, ALWAYS will cause Lynx +to set color mode on at startup if supported. +</ul> +If Lynx is built with slang, +this is equivalent to having included the -color command line switch +or having the COLORTERM environment variable set. If color support is +provided by curses or ncurses, this is equivalent to the default behavior +of using color when the terminal type supports it. If (n)curses color support +is available but cannot be used for the current terminal type, the preference +can still be saved but will have no effect. + +<p>A saved value of NEVER will +cause Lynx to assume a monochrome terminal at start-up. It is similar +to the -nocolor switch, but (when the slang library is used) can be overridden +with the -color switch. If the setting is OFF or ON when the current options +are saved to a '.lynxrc' file, the default start-up behavior is retained, +such that color mode will be turned on at startup only if the terminal info +indicates that you have a color-capable terminal, or (when slang is used) +if forced on via the -color switch or COLORTERM variable. This default +behavior always is used in anonymous accounts, or if the 'option'_save +restriction is set explicitly. If for any reason the start-up color mode +is incorrect for your terminal, set it appropriately on or off via this option. + +<H1><A NAME="CL">Show cursor for current link or option</A></H1> + +Lynx normally hides the cursor by positioning it to the right and if possible +the very bottom of the screen, so that the current link or OPTION is indicated +solely by its highlighting or color. If show cursor is set to ON, the cursor +will be positioned at the left of the current link or OPTION. This is helpful +when Lynx is being used with a speech or braille interface. It is also useful +for sighted users when the terminal cannot distinguish the character attributes +used to distinguish the current link or OPTION from the others in the display. + +<H1><A NAME="UM">User Mode</A></H1> + +<dl> +<dt><EM>Novice</EM>: Shows 2 extra lines of help at the bottom of the screen +for beginners. +<dt><EM>Intermediate (normal)</EM>: Normal status-line messages appear. +<dt><EM>Advanced</EM>: The URL is shown on the status line. +</dl> + +<H1><A NAME="VB">Verbose Images</A></H1> + +Controls whether or not Lynx replaces the [LINK], INLINE] and [IMAGE] comments +(for images without ALT) with filenames of these images. This is extremely +useful because now we can determine immediately which images are decorations +(button.gif, line.gif) and which are important. + +<H1><A NAME="VI">VI keys</A></H1> + +If set to 'ON' then the lowercase h, j, k and l keys will be mapped +to left-arrow, down-arrow, up-arrow and right-arrow respectively. +<p>The uppercase H, J, K, and L keys remain mapped to their configured bindings +(normally HELP, JUMP, KEYMAP and LIST, respectively). + +<H1><A NAME="DV">X DISPLAY variable</A></H1> + +If non-empty, it specifies your <A HREF="xterm_help.html">X terminal</A> +display address. + +<H1><A NAME="MB">Multi-bookmarks</A></H1> + +Manage multiple bookmark files: +<ul> +<li>When OFF, the default bookmark file is used for the 'v'iew-bookmarks +and 'a'dd-bookmark link commands. +<li>If set to STANDARD, a menu of available +bookmarks is always invoked when you seek to view a bookmark file +or add a link, and you select the bookmark file by its letter token +in that menu. +<li>If set to ADVANCED, you are instead prompted for the letter +of the desired bookmark file, but can enter '=' to invoke the STANDARD +selection menu, or RETURN for the default bookmark file. +</ul> + +<H1><A NAME="BF">Bookmark file</A></H1> + +Manage the default bookmark file: +<ul> +<li>If non-empty and multi-bookmarks is OFF, +it specifies your default '<A HREF="bookmark_help.html">Bookmark file</A>'. +<li>If multi-bookmarks is STANDARD or ADVANCED, +entering 'B' will invoke a menu in which you can specify +filepaths and descriptions of up to 26 bookmark files. +</ul> +The filepaths must be from your home directory and begin with './' +if subdirectories are included (e.g., './BM/lynx_bookmarks.html'). +<P> +Lynx will create bookmark files when you first 'a'dd a link, +but any subdirectories in the filepath must already exist. + +<H1><A NAME="AD">Assumed document character set</A></H1> + +This changes the handling of documents which do not explicitly specify +a charset. Normally Lynx assumes that 8-bit characters in those documents +are encoded according to iso-8859-1 (the official default for HTTP protocol). +Unfortunately, many non-English web pages forget to include proper charset +info; this option helps you browse those broken pages if you know somehow +what the charset is. When the value given here or by an -assume_charset +command-line flag is in effect, Lynx will treat documents as if they were +encoded accordingly. Option is active when 'Raw 8-bit or CJK Mode' is OFF. + +<H1><A NAME="DC">Display Character set</A></H1> + +This allows you to set up the default character set for your specific terminal. +The display character set provides a mapping from the character encodings +of viewed documents and from HTML entities into viewable characters. +It should be set according to your terminal's character set +so that characters other than 7-bit ASCII can be displayed correctly, +using approximations if necessary. You must have the selected character set +installed on your terminal. Since Lynx now supports a wide range of platforms +it may be useful to note that cpXXX codepages are used within IBM PC computers, +and windows-xxxx within native MS-Windows applications. + +<H1><A NAME="JK">Raw 8-bit or CJK mode</A></H1> + +This is set automatically, but can be toggled manually in certain cases: +it toggles whether 8-bit characters are assumed to correspond with the display +character set and therefore are processed without translation +via the chartrans conversion tables. ON by default when the display +character set is one of the Asian (CJK) sets and the 8-bit characters +are Kanji multibytes. OFF for the other display character sets, +but can be turned ON when the document's charset is unknown +(e.g., is not ISO-8859-1 and no charset parameter was specified +in a reply header from an HTTP server to indicate what it is), +but you have no better idea than viewing it as from display character set +(see 'assumed document character set' for best choice). Should be OFF +when an Asian (CJK) set is selected but the document is ISO-8859-1 +or another 'assumed document character set'. The setting can also be toggled +via the RAW_TOGGLE command, normally mapped to '@', and at startup +via the -raw switch. + +<H1><A NAME="FT">FTP sort criteria</A></H1> + +This allows you to specify how files will be sorted within FTP listings. +The current options include +`By Filename', `By Size', `By Type', `By Date'. + +<H1><A NAME="LD">List directory style</A></H1> + +Applies to Directory Editing. +Files and directories can be presented in the following ways: +<dl> +<dt><EM>Mixed style</EM>: Files and directories are listed together +in alphabetical order. +<dt><EM>Directories first</EM>: Files and directories are separated +into 2 alphabetical lists: directories are listed first. +<dt><EM>Files first</EM>: Files and directories are separated +into 2 alphabetical lists: files are listed first. +</dl> + +<H1><A NAME="DF">Show dot files</A></H1> + +If display/creation of hidden (dot) files/directories is enabled, +you can turn the feature on or off via this setting. + +<H1><A NAME="PC">Preferred Document Charset</A></H1> + +The character set you prefer if sets in addition to ISO-8859-1 and US-ASCII +are available from servers. Use MIME notation (e.g., ISO-8859-2) +and do not include ISO-8859-1 or US-ASCII, since those values are always +assumed by default. Can be a comma-separated list, which may be interpreted +by servers as descending order of preferences; you can make your order +of preference explicit by using `q factors' as defined by the HTTP protocol, +for servers which understand it: e.g., <kbd>iso-8859-5, utf-8;q=0.8</kbd>. + +<H1><A NAME="PL">Preferred Document Language</A></H1> + +The language you prefer if multi-language files are available from servers. +Use RFC 1766 tags, e.g., `en' English, `fr' French. Can be a comma-separated +list, and you can use `q factors' (see previous help item): +e.g., <kbd>da, en-gb;q=0.8, en;q=0.7</kbd> . + +<H1><A NAME="UA">User Agent</A></H1> + +The header string which Lynx sends to servers to indicate the User-Agent +is displayed here. Changes may be disallowed via the -restrictions switch. +Otherwise, the header can be changed temporarily to e.g., L_y_n_x/2.8.1 +for access to sites which discriminate against Lynx based on checks +for the presence of `Lynx' in the header. If changed during a Lynx session, +the default User-Agent header can be restored by deleting the modified string +in the Options Menu. Whenever the User-Agent header is changed, the current +document is reloaded, with the no-cache flags set, on exit from Options Menu. +Changes of the header are not saved in the .lynxrc file. +<P> +NOTE Netscape Communications Corp. has claimed that false transmissions +of `Mozilla' as the User-Agent are a copyright infringement, which will +be prosecuted. DO NOT misrepresent Lynx as Mozilla. The Options Menu issues +a warning about possible copyright infringement whenever the header is changed +to one which does not include `Lynx' or `lynx'. + +<H1><A NAME="LE">Line edit style</A></H1> + +This allows you to set alternate key bindings for the built-in line editor, +if your system administrator has installed alternates. +Otherwise, Lynx uses the <A HREF="edit_help.html">Default Binding</A>. + +<H1><A NAME="LL">Local execution links</A></H1> + +If set to 'ALWAYS ON', Lynx will locally execute commands contained +inside any links. This can be HIGHLY DANGEROUS, so it is recommended +that they remain 'ALWAYS OFF' or 'FOR LOCAL FILES ONLY'. + </BODY> </HTML> + diff --git a/src/HTAlert.c b/src/HTAlert.c index 017354a4..42aa340f 100644 --- a/src/HTAlert.c +++ b/src/HTAlert.c @@ -122,7 +122,7 @@ PUBLIC void HTReadProgress ARGS2( if (LYshow_kb_rate && (total >= kb_units || bytes >= kb_units)) { units = "KB"; - divisor = 1024; + divisor = kb_units; bytes /= divisor; if (total > 0) total /= divisor; } @@ -132,7 +132,7 @@ PUBLIC void HTReadProgress ARGS2( else sprintf (line, "Read %ld %s of data", bytes, units); if ((transfer_rate > 0) - && (!LYshow_kb_rate || (bytes * divisor > kb_units))) + && (!LYshow_kb_rate || (bytes * divisor >= kb_units))) sprintf (line + strlen(line), ", %ld %s/sec.", transfer_rate / divisor, units); else sprintf (line + strlen(line), "."); diff --git a/src/LYCurses.h b/src/LYCurses.h index ace10813..48bea1e5 100644 --- a/src/LYCurses.h +++ b/src/LYCurses.h @@ -392,9 +392,12 @@ extern void lynx_stop_radio_color NOPARAMS; extern void lynx_stop_all_colors NOPARAMS; /* - * To prevent corrupting binary data with _WINDOWS and DJGPP we open files and - * stdout in BINARY mode by default. Where necessary we should open and + * To prevent corrupting binary data on DOS, MS-WINDOWS or OS/2 we open files + * and stdout in BINARY mode by default. Where necessary we should open and * (close!) TEXT mode. + * + * Note: EMX has no corresponding variable like _fmode on DOS, but it does + * have setmode. */ #if defined(_WINDOWS) || defined(DJGPP) || defined(__EMX__) #define SetOutputMode(mode) setmode(fileno(stdout), mode) diff --git a/src/LYDownload.c b/src/LYDownload.c index e55d0dbc..acf6d882 100644 --- a/src/LYDownload.c +++ b/src/LYDownload.c @@ -614,15 +614,20 @@ PUBLIC int LYdownload_options ARGS2( BeginInternalPage(fp0, DOWNLOAD_OPTIONS_TITLE, DOWNLOAD_OPTIONS_HELP); fprintf(fp0, "<pre>\n"); + + fprintf(fp0, "\ + <em>Downloaded link:</em> %s\n", + downloaded_url); + + if (!no_disk_save && !child_lynx) fprintf(fp0, "\ - <em>Downloaded link:</em> %s\n\ <em>Suggested file name:</em> %s%s\n", - downloaded_url, (lynx_save_space ? lynx_save_space : ""), sug_filename); + (lynx_save_space ? lynx_save_space : ""), sug_filename); fprintf(fp0, "\n%s options:\n", (user_mode == NOVICE_MODE) ? "Standard download" : "Download"); - if(!no_disk_save && !child_lynx) { + if (!no_disk_save && !child_lynx) { #ifdef DIRED_SUPPORT /* * Disable save to disk option for local files. diff --git a/src/LYHistory.c b/src/LYHistory.c index fe077e48..20126cc9 100644 --- a/src/LYHistory.c +++ b/src/LYHistory.c @@ -121,8 +121,8 @@ PUBLIC BOOLEAN LYwouldPush ARGS1( char *, title) { return (!strcmp(title, HISTORY_PAGE_TITLE) - || !strcmp(title, PRINT_OPTIONS_TITLE) - || !strcmp(title, DOWNLOAD_OPTIONS_TITLE) + || !strcmp(title, PRINT_OPTIONS_TITLE) + || !strcmp(title, DOWNLOAD_OPTIONS_TITLE) #ifdef DIRED_SUPPORT || !strcmp(title, DIRED_MENU_TITLE) || !strcmp(title, UPLOAD_OPTIONS_TITLE) @@ -322,6 +322,11 @@ PUBLIC void LYpop ARGS1( doc->isHEAD = history[nhist].isHEAD; doc->safe = history[nhist].safe; doc->internal_link = history[nhist].internal_link; +#ifdef DISP_PARTIAL + /* assume we pop the 'doc' to show it soon... */ + Newline_partial = doc->line; /* reinitialize */ + NumOfLines_partial = -1; /* initialize to -1 */ +#endif /* DISP_PARTIAL */ CTRACE(tfp, "LYpop[%d]: address:%s\n title:%s\n", nhist, doc->address, doc->title); } @@ -347,6 +352,11 @@ PUBLIC void LYpop_num ARGS2( doc->isHEAD = history[number].isHEAD; doc->safe = history[number].safe; doc->internal_link = history[number].internal_link; /* ?? */ +#ifdef DISP_PARTIAL + /* assume we pop the 'doc' to show it soon... */ + Newline_partial = doc->line; /* reinitialize */ + NumOfLines_partial = -1; /* initialize to -1 */ +#endif /* DISP_PARTIAL */ } } diff --git a/src/LYMain.c b/src/LYMain.c index 49d6d3e5..e749f638 100644 --- a/src/LYMain.c +++ b/src/LYMain.c @@ -564,13 +564,13 @@ PUBLIC int main ARGS2( #endif /* - * To prevent corrupting binary data with _WINDOWS and DJGPP + * To prevent corrupting binary data on DOS, MS-WINDOWS or OS/2 * we open files and stdout in BINARY mode by default. * Where necessary we should open and (close!) TEXT mode. * (use LYNewTxtFile/LYAppendToTxtFile to open text files for writing) */ SetDefaultMode(O_BINARY); - SetOutputMode( O_BINARY ); + SetOutputMode(O_BINARY); #ifdef DOSPATH if (getenv("TERM")==NULL) putenv("TERM=vt100"); diff --git a/src/LYMainLoop.c b/src/LYMainLoop.c index 51c0fd88..5d062f73 100644 --- a/src/LYMainLoop.c +++ b/src/LYMainLoop.c @@ -505,14 +505,16 @@ try_again: /* and set the flag to 0 */ if (display_partial) { /* - * Disable display_partial if requested URL has #fragment. + * Disable display_partial if requested URL has #fragment + * and we are not popped from the history stack + * so can't calculate correct newline position for fragment. * Otherwise user got the new document from the first page * and be moved to #fragment later after download - * completed, but only if user did not mess screen up by + * completed, but only if s/he did not mess screen up by * scrolling before... So fall down to old behavior here. */ if (!LYCursesON || - (strchr(newdoc.address, '#'))) + (Newline_partial == 1 && strchr(newdoc.address, '#'))) display_partial = FALSE; } #endif /* DISP_PARTIAL */ @@ -985,7 +987,8 @@ try_again: * Override newdoc.line with a new value if user * scrolled the document while downloading. */ - if (Newline_partial != newdoc.line) + if (Newline_partial != newdoc.line + && NumOfLines_partial > 0) Newline = Newline_partial; /* @@ -4928,7 +4931,6 @@ check_add_bookmark_to_self: newdoc.isHEAD = history[number].isHEAD; newdoc.safe = history[number].safe; newdoc.internal_link = FALSE; - newdoc.line = curdoc.line; /* need for display_partial ! */ newdoc.link = 0; HTOutputFormat = HTAtom_for("www/download"); LYUserSpecifiedURL = TRUE; @@ -5007,7 +5009,6 @@ check_add_bookmark_to_self: newdoc.safe = FALSE; } newdoc.internal_link = FALSE; - newdoc.line = curdoc.line; /* need for display_partial ! */ newdoc.link = 0; HTOutputFormat = HTAtom_for("www/download"); /* diff --git a/src/LYUtils.c b/src/LYUtils.c index ac66b7f7..7808d659 100644 --- a/src/LYUtils.c +++ b/src/LYUtils.c @@ -2822,18 +2822,23 @@ PUBLIC BOOLEAN inlocaldomain NOARGS #include <sys/ioctl.h> #endif -/* For systems that have both, but both can't be included, duh */ -#ifdef TERMIO_AND_TERMIOS +/* For systems that have both, but both can't be included, duh (or neither) */ +/* FIXME: this whole chunk may be redundant */ +#ifdef TERMIO_AND_CURSES # include <termio.h> -#else -# ifdef HAVE_TERMIOS_H -# include <termios.h> # else -# ifdef HAVE_TERMIO_H -# include <termio.h> -# endif /* HAVE_TERMIO_H */ -# endif /* HAVE_TERMIOS_H */ -#endif /* TERMIO_AND_TERMIOS */ +# ifdef TERMIO_AND_TERMIOS +# include <termio.h> +# else +# ifdef HAVE_TERMIOS_H +# include <termios.h> +# else +# ifdef HAVE_TERMIO_H +# include <termio.h> +# endif /* HAVE_TERMIO_H */ +# endif /* HAVE_TERMIOS_H */ +# endif /* TERMIO_AND_TERMIOS */ +#endif /* USE_TERMIO_H */ PUBLIC void size_change ARGS1( int, sig GCC_UNUSED) @@ -3010,6 +3015,14 @@ PUBLIC void change_sug_filename ARGS1( } FREE(temp); + if (fname[strlen(fname) - 1] == '/') + /* + * Hmm... we have a directory name. + * It is annoying to see a scheme+host+path name as a suggested one, + * let's remove the last_slash and go ahead like we have a file name. - LP + */ + fname[strlen(fname) - 1] = '\0'; + /* * Remove everything up the the last_slash if there is one. */ @@ -1216,12 +1216,12 @@ * the version definition with the Project Version on checkout. Just * ignore it. - kw */ /* $Format: "#define LYNX_VERSION \"$ProjectVersion$\""$ */ -#define LYNX_VERSION "2.8.1pre.6" +#define LYNX_VERSION "2.8.1pre.7" #define LYNX_WWW_HOME "http://lynx.browser.org/" #define LYNX_WWW_DIST "http://www.slcc.edu/lynx/current/" #define LYNX_RELEASE FALSE /* $Format: "#define LYNX_DATE \"$ProjectDate$\""$ */ -#define LYNX_DATE "Thu, 01 Oct 1998 07:15:55 -0600" +#define LYNX_DATE "Sun, 04 Oct 1998 10:51:58 -0600" #define LYNX_DATE_OFF 5 /* truncate the automatically-generated date */ #define LYNX_DATE_LEN 11 /* truncate the automatically-generated date */ #define LYNX_RELEASE_DATE "1998" @@ -1286,11 +1286,6 @@ #define INSTALL_PATH "install" #define TAR_PATH "tar" #define TOUCH_PATH "touch" - -/* -** WINDOWS/DOS -** =========== -*/ #define ZIP_PATH "zip" #define UNZIP_PATH "unzip" #define MKDIR_PATH "mkdir" |