Changes for vile 7.3 (released Mon Dec 8, 1997) (tom) 971207 (t) + correct include-path for configure script's check for missing externs, to work with --srcdir option (analysis by Kevin Buettner). (tom) 971205 (s) + add logic to configure.in to use a filter (installed by td_lib) named 'td_config' which works around limited 'sed' when constructing config.h on SCO 3.x, HP-UX 9.x and other antiquated platforms. + add configure options --disable-extensions (SMALLER, FEWNAMES) and --disable-shell (OPT_SHELL), and --with-dmalloc. The shell option is experimental; note that a genuinely secure editor should not allow directory names to be specified (but I think that's the only omission). + add fallback for tparam/tparm in tcap.c (for EMX, but usable for genuine termcap systems such as SunOS 4.x), to support color. + add files for building termcap version on OS/2 with EMX (makefile.emx, config.emx and os2keys.h). + change $shell to use $COMSPEC on OS/2, MS-DOS, etc. This is needed for the OS/2 EMX configuration, but useful in the others. + modify configure script to use ifdef's in estruct.h when testing for missing extern/prototype declarations rather than a separate list in aclocal.m4 (this requires rebuild/test on most platforms). + combine configure-tests for errno, sys_nerr and sys_errlist. + minor fixes: new versions of CF_NCURSES_LIBS, CF_ADD_INCDIR, CF_CHECK_CACHE, CF_NCURSES_CPPFLAGS. + correct handling of :map containing ".", which was being handled as if the "." always appeared at the end (patch by Duncan Sargeant; input.c, map.c). (kev) 971203 (r) + api.c (lreplace): Fix marks up. This won't always be right, but at least it'll be closer. We need a way to modify marks and attributes from perl. (setup_fake_win): changed return type to int. (api_fscreen, api_edit, api_swscreen, api_bp2sp): new functions. (sp2bp, bp2sp): Removed these macros. + api.h (api_swscreen, api_fscreen, api_bp2sp): declared these functions. (sp2bp, bp2sp): macros moved from api.c. + configure.in (LINK_PREFIX): set this variable. (From Brendan O'Dea.) (CFLAGS, LIBS): Use $perl_bin_path instead of perl in the --with-perl section. + makefile.in (LINK): Prepend LINK_PREFIX as determined by configure to the link command. (From Brendan O'Dea.) + perl.xs (newVIrv): Don't allocate api private part here. (It's allocated in api_bp2sp now.) The second parameter has also changed; changed all callers. (perl): Print error messages and warnings to message line. (perl_init): Setup warning handler. Also tie STDOUT and STDERR so that output to these filehandles will be printed on the message line. (Thanks to Brendan O'Dea.) (perl_eval): New function. (Msg): Rewritten to handle multiple arguments. (From Brendan O'Dea.) (GetLines): new function which fetches all lines in the range. (Edit, FindScreen, SwitchScreen, Warn): New functions. + proto.h (perl_free_private): removed. (perl_free_handle): added. + ptypemap (T_VI): Translate C null pointers to perl undefs. (tom) 971128 (q) + modify tagignorecase mode to use lowercased keys in the binary-tree, and applying tagignorecase mode to the search within the tagged file, making this behave as Joseph F. Garvey requested. + implement tags-completion. + replace Alex Wetmore's binary tree code with a balanced binary tree module that's a little more general, and does deletion more rapidly than my first try. + minor fixes for foreground/background colors when resizing terminal window so minibuffer is painted correctly (display.c, ntconio.c). + rename ntvile to winvile. (tom) 971112 (p) + correct logic for minibuffer by ensuring that it is not marked for undo, and that the value of MK is save/restored when modifying the minibuffer. (tom) 971109 (o) + correct range of scrolling region in ansi.c + correct treatment in xshell.sh for no-arguments. + change TTrev() / TTattr() parameter to unsigned. + implement mouse and flash in OS/2 VIO driver (os2vio.c). + correct logic in vtputc() to prevent minibuffer from writing into the lower-right corner of the screen. (tom) 971108 (n) + more CSet unsigned/signed compiler warning fixes (estruct.h) + don't reopen terminal in ansi.c if it is already open. + correct handling of rename-buffer when it is a scratch buffer that does not happen to be a stored procedure. + recorrect lookup_namebst() call in engl2fnc(); it should always allow partial match. Fixed by adding a third mode where the lexical first match will be returned rather than the middle one in a range. + correct tab-position in ntconio.c + modify borland.c to reset colors when exiting or running a shell. + change tcapkopen() to reflect possibility that terminal initialization string moves the cursor. + add simple gui terminal driver for WinNT (ntwinio.c, makefile.wnt). Built with Microsoft Visual C++ 4.1, both with IDE and makefile.wnt. Use "nmake -f makefile.wnt cfg=ntvile". + integrated related patch by Clark Morgan for repainting the screen correctly after a :stop command. + rewrote internals of command/message line to make it a one-line minibuffer, including mods for OPT_RAMSIZE and OPT_WORKING. Tested Linux (for tcap.c, x11.c, ansi.c), OS/2 (os2vio.c), WinNT (ntconio.c, ntwinio.c), VMS (vmsvt.c), djgpp (borland.c). (tom) 971028 (m) + correct inverted parameter in call on lookup_namebst(). + compiler warnings from Solaris (unsigned vs signed in bind.c, ifdef in trace.c). + minor changes to compile on OS/2 with EMX. + modify borland.c to reset colors to white/black on exit. (tom) 971027 (l) + backout change to own_selection, since it doesn't follow ICCCM, in the sense that it increases X traffic needlessly (pointed out by Kevin Buettner). Kept check on return value from XtOwnSelection. + correct out-of-bounds indexing in dname_to_dirnum() by adding a length parameter, use memcmp. + modify Alex's change so that buffers that are renamed or deleted update the corresponding entries in the binary-tree. Also, don't allow built-in commands to be removed or replaced. Finally, make the name-completion work with an empty command. + add $end-of-cmd variable (patch by Alex Wetmore). + integrate patch by Alex Wetmore that makes stored procedures act just like built-in commands, i.e., able to run them from the : prompt. This works by building a binary tree of all of the command and procedure names. (tom) 971015 (k) + add configure options --with-Xaw-scrollbars and --with-drag-extension. These make it easy to build xvile with Kevin's scrollbars by specifying --without-Xaw-scrollbars, or to use the Xaw's default translations for scrollbars by specifing --without-drag-extension. + ifdef'd out the code that invokes $xshell in ":!command". + correct logic in xvile that spawns a new instance from menu entry, was leaving a zombie when the new instance closed (reported by Brian Moore ). + modify own_selection to always try to own the select, as well as to check the return value from XtOwnSelection (reported by Ian Jamison ) + add Lesstif-specific ifdef for workaround (requested by Larry Gensch). + correct ifdef'ing of Motif version of xvile (reported by Larry Gensch). + add screen types Xol and Xm as aliases for OpenLook and Motif. + correct quoting in configure script for OpenLook case. + fix some compiler warnings and add 'make check' target (reported by Nelson H. F. Beebe ) (kev) 971013 (j) + perl.xs, ptypemap: Lots of new code which extends the perl interface a bit more. + api.c, api.h: New files which sort of implement nvi's API for extension languages. + makefile.in (OBJ, VILESRC): Added api.o and api.c to these lists. + estruct.h (BUFFER): Added new field, b_api_private, used by the extension language API. + buffer.c (FreeBuffer): Free up the extension language API related data structure referenced by b_api_private. (bfind): Initialize the b_api_private field. + cmdtbl (perl): Put in a reasonable set of flags for this command. (It used to be NONE.) + exec.c (execute_named_command): Added region support for the perl command. + proto.h (push_fake_win, pop_fake_win, perl_default_region, perl_free_private, api_free_private): New prototypes. + select.c, window.c (push_fake_win, pop_fake_win): These functions removed from select.c and put into window.c. Also they are no longer static. (kev) 971009 (i) + perl.xs, ptypemap: New files. Beginnings of perl interface for vile. + cmdtbl (perl): New command enabled only when --with-perl supplied as an option to the configure script. + configure.in, makefile.in: perl related changes. + (fix typo in xshell.sh - tom) (tom) 971008 (h) + correct typo in stubbed-out code for $xshell, add $xdisplay and example script 'xshell.sh' which can be used to run a shell command from xvile, prompting at the end so that the output doesn't go away when the xterm completes. + rename vile's ctype macros to mixed-case to avoid conflict. This is needed for Solaris 2.6, which does not implement ctype as macros. + modify casts and some names (e.g., new, operator, class) to allow compiling with C++ (tested with g++ 2.7.2 on Linux). (kev) 971007 (g) + x11.c (multi_click): Reimplemented multiclick selections for lines. Previously, it was not possible to select the entirety of a wrapped line by clicking on a row other than the first row. + window.c (mvupwind, onlywind, delwp, splitw, enlargewind, shrinkwind): Make sure that w_line.o is zero just after setting w_line.l to a new value. The lack of this assignment in mvupwind() was causing a SEGFAULT on my linux box. [To test it, create a very long wrapped line with a bunch of lines (say 100) before it; my test has in excess of 10,000 characters on the long line. Make sure linewrap mode is set. Then say 100^Y. The SEGFAULT was immediate. You can also reproduce it by dragging the scrollbar for awhile.] (tom) 971006 (f) + document --with-screen values better in configure --help. + implement Athena widget scrollbar support in x11.c, using Kevin's dragging support from the no-widget case. + add $xshell environment variable, use this to control :sh command from xvile. + new CF_X_ATHENA configure macro adds configure options --with-Xaw3d and --with-neXtaw. + corrected CF_IMAKE_CFLAGS, which was not using the imake symbol that specified X function prototypes. (This was old behavior, which did not seem to matter until adding Xaw scrollbars on Linux). (kev) 971005 (e) + basic.c (setwmark): In linewrap mode, account for undisplayed rows before the first row shown of a very long wrapped line. + display.c (vtset): Don't allow wrapped lines to overflow onto the mode line. I don't think characters from the buffer were ever getting written to the modeline, but vteeol() would sometimes erase the modeline when displaying very long wrapped lines. (reframe): Handle reframes of long wrapped lines more gracefully. In particular, once the top row of a very long wrapped line goes off the top, it is now possible to have the cursor positioned on somewhere other than the bottom row. Scrolling up or down via right or left right movement within a long wrapped line also looks a lot better now. (updattrs): Don't attempt to access rows before the top row of a window when updating attributes. Also, don't access rows of or below the the mode line. This fixes a SEGFAULT. (tom) 970918 (d) + amend logic for find_mode() so that "&glo cmode" and "&loc cmode" work as before majormode changes (reported by Sean Ahern). + merge autoconf macros from tin/xterm, which mainly affect the configuration tests for ncurses and imake $CFLAGS, used to augment autoconf's tests for X Windows. + also (since some systems have deficient 'sed' programs) provide alternate hook for using a program 'td_config', which is currently bundled in td_lib.tgz, that does the sorting operation of config.h in a reasonably portable manner. + add mode 'maplength' to control the maximum length of a map string. + correct definition of OUTC_ARGS for the case where it should be a 'char' value (patch by Jason Molenda ). (tom) 970907 (c) + modify CF_CACHE_CHECK macro to use AC_CANONICAL_HOST to obtain a "better" value for SYSTEM_NAME. This is displayed as part of the :version command. Add config.guess and config.sub to support this. + changes for 7.2b omitted some macros dealing with echoing during the make process (reported by Jens Schleusener ) (tom) 970905 (b) + merge configure macros from tin-unoff and lynx (configure.in, aclocal.m4). + rename configure macros to CF_ prefix, for consistency/merge with other programs (configure.in, aclocal.m4). + correct handling of tparm return-value; it must not be freed, at least for SVr4 and ncurses (tcap.c) + ensure that majormode names are a legal identifier. + modify so that majormode names can be mixed case (requested by Sean Ahern). (tom) 970904 (a) + add variable $majormode so that it can be tested in a script (requested by Philippe Chassany). + fix potential ifdef problem for cbuf1 (reported by Brendan O'Dea). + simplified VMS permissions code, using the protection parameter in 'open()' to achieve the objective of propagating a file's current protection, as well as making it compile with DEC C (reported by Simon Hefti ). Changes for vile 7.2 (released Thu Sep 4, 1997) (tom) 970903 (k) + modify rename-buffer so that if we rename a buffer, we'll clear the flag that marks it for removal when popped-down. + modify show-modes command so that it will format more than 3 columns if the screen is wide enough. + correct logic of delfrommap(), which dumped core when unmapping a single-character map (reported by Paul Fox). + modify show-majormodes so that giving a count will make it show all of the submodes prefixed by the majormode name, e.g., c-suffixes (suggested by Paul Fox). + modify documentation to use "define-majormode" and "remove-majormode" for clarity, other related fixes to documentation (suggested by Paul Fox). (tom) 970902 (j) + correct logic in find_mode() that did not find majormode qualifiers for majormodes that began similarly (e.g., "com" masked by "c"). + correct an uninitialized variable in per_submode(), found by Purify. + correct ifdef'ing in tcap.c, from 7.1i, when neither tparm nor tparam is found. (tom) 970901 (i) + if the command-line '@' option is used, set the $startup-file variable to correspond to the startup file which is used. + add tagignorecase mode, which causes tag searches to be done ignoring case (requested by Joseph F. Garvey ). + initialize last_eolchar in docmd() so that 'set' command works properly in a macro. + add %B substition for error-buffer regular expressions to allow using [Standard Input] and other scratch buffers as error buffers. + modify format-til command to treat '#' specially when in cmode, so no whitespace is inserted after it. + modify format-til command to support comment-prefix mode and handle repeated prefix, so that, for example, vile can now format multiple levels of email replies. + add comment-prefix mode, which specifies a regular expression that controls the portion of a line which is prefixed when formatting. + modify default setting of comments mode to make repeated prefix match (e.g., "> > >", is different from "> >"). + ensure that imdying() always exits (reported by Clark Morgan). + workaround for incompatible interpretation of termcap Sf/Sb capability with BSD vs SYSV platforms (tcap.c). (tom) 970829 (h) + correct initialization of $palstr on OS/2. + correct some of the signed/unsigned warnings from IBM CSet compiler. + remove obsolete autoconf fallback macros. + correct handling of ":abbr res RES", ":abbr wres WRES" combination by forcing matches on these to check that the beginning of the match is an identifier boundary (reported by Paul Laub ). + correct assignment in maplookup() which caused a -1 returned when no more characters were available for matching to be converted to the 0xFF character. + modify fopen-for-write calls on VMS to add "0" argument, which makes the new file get the user's default protection (requested by Brian Reed ). + correct logic that allowed repeated definition of submodes (reported by Duncan Sargeant). + allow submode names to begin with "no", assuming they are booleans (reported by Duncan Sargeant). + corrected lookup of hyphenated submodes, e.g., c-tabstop (reported by Duncan Sargeant ). + allow define-submode to accept an '=' between the submode and its value. + modify define-mode and remove-mode to suppress warning message if the mode does not exist, since this produces unnecessary warnings when re-sourcing .vilerc + include only where it is needed, halving the build time (patch by Clark Morgan). + modify configure script to work with CLIX old-style shared libraries (e.g., -lc_s) needed for xvile. (tom) 970816 (g) + correct type mismatch in filec.c when sizeof(size_t) != sizeof(unsigned) (reported by Larry Gensch ). + modify vmsbuild.com to tell MMS (or MMK) to ignore warnings, workaround for an inconsistency between versions of DEC C (suggested by Andy Harper and Adam Denton). + initial implementation of majormodes, which supports grouping of buffer modes, together with qualifiers (e.g., cmode and c-suffixes). New commands include define-mode, define-submode, remove-mode, remove-submode, list-majormodes. (Most changes are in mktbls.c and modes.c). (tom) 970619 (f) + modify ":set" command so that it does not force a mode to be set, but instead shows the local buffer and window settings. + correct missing error-test in logic that sets regular-expression modes (reported by Philippe Chassany). + add configure option to specify the total numbered macros available, e.g., execute-macro-1, ifdef'd with OPT_EXEC_MACROS (requested by Philippe Chassany). + modify xvile menus to allow arbitrary command line rather than bound functions (exec.c, menu.c). + correct spurious parameter in vms2unix.c, from 7.1d changes. (tom) 970607 (e) + modify VMS terminal driver, vmsvt.c, to work when invoked from a command-file, i.e., get terminal characteristics from SYS$COMMAND rather than SYS$INPUT (reported by Adam Denton). + treat '$' as an identifier character on VMS (requested by Adam Denton). + clarify discussion of color in help-file (patch by Clark Morgan). + modify map.c to use TBUFF's, as well as new kbd_reply interface, to remove limit on mapped strings. + change interface/internals of kbd_reply() to use a TBUFF, so we don't need fixed-size buffers any more (bind.c, exec.c, eval.c, history.c, input.c, line.c, modes.c). + correct uninitialized buffer in loadkreg(). + correct indexing in display_cursor() function in xvile; exposed when displaying a long list for the historical buffer command. (tom) 970526 (d) + add $ncolors variable to allow run-time modification of the meaning of colors (e.g., white). + change $palette to a dynamically allocated string. + modify termcap and IBM terminal drivers to support 16 colors. Note that the termcap driver can do this only when configured against a terminfo library (inspired by a patch from Clark Morgan). + modify mktbls to generate the enumerated choices tables (i.e., for color, visual-matches) to simplify ifdef'ing these between the 8-color and 16-color configurations. + undo some of the const parameters of functions, thereby eliminating most of the places where casts were used to remove const. + modify VMS processing of tags to strip file's version number (adapted from fix by Adam Denton ). + modify bclear() to free attributes before removing the buffer's lines, thereby making it faster (patch by Ian Jamison). (tom) 970513 (c) + set local buffer mode for 'dos' in slowreadf(), which fixes the problem of that function modifying the global mode when piping a file to vile, hence causing syntax errors in vile.rc when it contains trailing carriage-returns (file.c) (analysis by Clark Morgan). + correct missing VASEL flag that caused 'q' command on OS/2 to not display highlighting, missed in 7.0b (os2vio.c) (reported by George Eccles ) + implement 'flash' for WinNT (ntconio.c) (tom) 970513 (b) + ifdef'd menu.c to work with 7.1a (tom) 970512 (a) + modify has_C_suffix() to ignore case on platforms where filename case should be ignored (reported by Emil Rojas ). + add version in vmsbuild.com to release_warnings + remove unnecessary test for Xaw/SimpleMenu.h (configure.in). + improve geometry of Xaw menus using Box (patch by Brendan O'Dea ) + add menu.c to the modules for xvile on VMS (reported by Graeme Miller). Changes for vile 7.1 (released Wed May 8, 1997) (tom) 970508 (none) + undo a place where I'd dropped an XtVaGetValues() call, since it appeared redundant, but was not - affects only Xaw build (x11.c). + ifdef'd a test in newscreensize() that is applicable only when OPT_WORKING is set; this had broken screen initialization on MS-DOS (display.c). (tom) 970507 (l) + add resource to control menu-height (x11.c, menu.c). + correct definition in vms2unix.c to allow compile with VAX C, which doesn't like "#define foo xxx.foo". (tom) 970430 (k) + modify lookup of .vilerc to use startup-file search rules (menu.c) + correct missing XmString conversion (menu.c) + add configure check for -lXext to support Athena build on X11R4. (tom) 970429 (j) + use im_waiting() function to reset "working..." state after executing a menu-command (menu.c). + modify lookup of .vilemenu to use startup-file search rules. + corrections for porting Xaw version to SunOS, etc., with X11R4 and X11R5 (x11.c, configure.in) (tom) 970428 (i) + implement Xaw (Athena widget) version of menus. Simplified buffer lookup function for menus, align/document resource names (menu.c, x11.c, configure script). + correct minor memory leaks during initialization (main.c) + correct array-indexing error that caused core dump when selecting line-wrapped text, moving cursor up (display.c). (tom) 970422 (h) + improved example of menus for xvile (Philippe Chassany). + correct mistyped index in c-filt.c, which was a char (patch by Ian Jamison). + correct c-filt.c handling of nested comment delimiters (patch by Ian Jamison ) + correct sign-extension in tcap.c for xterm mouse-coordinates. (tom) 970407 (g) + add mode 'tagword', which allows user to lookup the whole word rather than a substring. (from Adam Denton ). + reintroduce flag 'i_displayed' into 'working' mode (I'd forgotten that it suppressed the message until screen-mode). + improve buffer-switching in menu-support (patch by Philippe Chassany) + correction to MS-DOS, etc., where attempt was made to fclose a file pointer that was out of scope (patch by Clark Morgan). + modify definition of eql_bname() macro so that buffer names are treated as case-insensitive where filenames are, e.g., WinNT and OS/2 (patch by Rick Sladkey from report by Clark Morgan). + add predefined regular expression to finderr.c to improve support for MS-DOS pathnames (patch by Clark Morgan). (tom) 970407 (f) + integrated menu-support for Motif xvile (patch by Philippe Chassany ). + refined changes to 'working' mode to ensure that the "working..." message is cleared when the timer elapses. (kev) 970407 (e) + fileio.c (isready_c): Small tweak to the ifdefs for mklinux w/ shared libraries. This'll probably be needed for other systems with the up and coming GNU libc as well. (tom) 970330 (d) + correct missing ']' on generated buffer name for shell output, e.g., "[!ls]" rather than "[!ls" (reported by Paul Fox): (file.c). + correct unnecessary escaping of '!' in prompts that are not expanding the shell contents (reported by Paul Fox): (input.c). + modify semaphore used by 'working' mode to make the SIGALRM timer elapse when it is not in use, allowing idle process to swap out properly (reported by Bill Kipp): (display.c, etc). + correct filename parsing for MS-DOS/etc configuration by checking for device name (patch by Clark Morgan). (tom) 970322 (c) + fixes for piping to vile in WinNT (patch by Clark Morgan). + add logic for visual-matches in color, WinNT (patch by Clark Morgan). + add vile-c-filt.exe to makefile.wnt, modify default keyword file on that system to vile.keywords (patch by Clark Morgan). + correct problem with MS-DOS/Win95/NT version of npopen.c that left temp-files after reading from pipe, because file-remove was done before closing (patch by Clark Morgan). (tom) 970315 (b) + use macro GCC_UNUSED throughout to quiet gcc warnings about unused (dummy) parameters. + modify configure script to use VC_GCC_WARNINGS + add mode to control whether formatting adds one or two spaces after sentences (patch by Otto Lind). + handle C++ comments (patch by Otto Lind ). + implement colored attributes in OS/2 video driver (os2vio.c) + modify writereg() so that it recomputes the region size after invoking the $write-hook; this is necessary since it may change the file's size (reported by Bob Wall ). (tom) 970314 (a) + modify c-filt.c, manfilt.c to simplify compiling w/o auto-configure "config.h". + modify MS-DOS/Win31/WinNT portion of npopen.c to leave input file descriptor alone when reading from pipe, solving a problem with applications hanging under Thompson Toolkit (patch by Clark O. Morgan ) + correct inequality changed in 6.2g which is part of right-margin threshold computation (report and fix by William Yuan ) + corrected definition of $(exec_prefix) in makefile.in (reported by Joachim Schimpf ). + apply suggested casts in vms2unix.c to appease DEC C 5.3 (reported by Andy Harper and Graeme Miller). This change log started on Wednesday Mar 12, 1997.