diff --git a/CHANGES b/CHANGES index f68748e..dd63b0c 100644 --- a/CHANGES +++ b/CHANGES @@ -1,9 +1,20 @@ +New in release 1.5.0 +==================== + +* Terminal window resizeable +* fix build fails with gcc-15/C23 +* fix statusline for small windows +* various issues caught by lintian solved +* fix old-style-definition warnings +* Minor fixes + + New in release 1.4.2 ==================== This release is dedicated to Sven Guckes (*1967-04-06 +2022-02-20). -Sven was an enthusiastic Linux explainer, his particular passion was the console tools. +Sven was an enthusiastic Linux explainer, his particular passion was the console tools. I met Sven a couple of times. He always showed interest in the further development of -the bvi and liked to discuss new ideas. +the bvi and liked to discuss new ideas. R.I.P. Sven * :wq bug fixed @@ -29,7 +40,7 @@ New in release 1.4.1rc * Compile warning: implicit declaration of function ‘save_chk’ fixed (SF bug #9) * bmore seg fault on file not found fixed * set columns prevents filename display on the commandline fixed (SF bug #8) -* bmore new option -r +* bmore new option -r bvi new setting: set reverse Characters between 160 - 254 are displayed as "reverse video text" as used in some legacy systems (Atari, Commodore, Apple II, etc). @@ -128,9 +139,9 @@ New in release 1.3.0 * Reading of Block Special Files * New Command line options: +cmd - -b begin \ - -e end > for partial file read - -s size / + -b begin \ + -e end > for partial file read + -s size / * :e# bug fixed * Debian bug #68436 (Buffer overflow in io.c) fixed diff --git a/CREDITS b/CREDITS index da1582b..cf930a1 100644 --- a/CREDITS +++ b/CREDITS @@ -1,7 +1,7 @@ Patches: -Guido sys_errlist -Christian "naddy" Weisgerber {Free,Open}BSD -Gunnar Larisch ^ZZ bug +Etienne Mollier gcc-15/C23 issues +Matthias Klose GCC-15 issues +Vincent Batts nit cleanup Peter J. Holzer setlocale Albert Chin-A-Young Makefile.in Ralf AIX fixes diff --git a/Makefile.in b/Makefile.in index 5f67d29..81a596e 100644 --- a/Makefile.in +++ b/Makefile.in @@ -8,7 +8,7 @@ # # Copyright (c) 1996-2022 by Gerhard Buergmann # gerhard@puon.at -# +# # 1996-01-18 V 1.0.0 # 1999-01-15 V 1.1.0 # 1999-03-03 V 1.1.1 diff --git a/README b/README index 4a63d35..c6c2e2c 100644 --- a/README +++ b/README @@ -9,12 +9,12 @@ and is distributed under the GPL (GNU Public License). How to compile ============== - You need the curses (ncurses) library for cursor movement on your system. + You need the curses (ncurses) library for cursor movement on your system. https://www.cyberciti.biz/faq/linux-install-ncurses-library-headers-on-debian-ubuntu-centos-fedora/ - gunzip -c bvi-1.4.2.src.tar.gz | tar xvf - - cd bvi-1.4.2 + gunzip -c bvi-1.5.0.src.tar.gz | tar xvf - + cd bvi-1.5.0 ./configure make make install @@ -32,14 +32,6 @@ To avoid this behaviour use: stty dsusp undef ---------------------------------------------------------------------------- -Subscribe to the bvi mailing for support, updates and other news: - - Send a blank email to bvi-subscribe@yahoogroups.com. You will receive a - subscription confirmation message. Simply reply this message and your - subscription will be complete. - - --------------------------------------------------------------------------- PLEASE send any bug reports (and fixes), code for new features, comments, questions, etc. (even flames) to: diff --git a/acconfig.h b/acconfig.h index 7589674..2eaf7ce 100644 --- a/acconfig.h +++ b/acconfig.h @@ -10,4 +10,4 @@ #undef NEED_PUTC_CHAR -#undef HAVE_NCURSES_TERM_H +#undef HAVE_NCURSES_TERM_H diff --git a/bm_dos.c b/bm_dos.c index 29ccf8c..ba2ed25 100644 --- a/bm_dos.c +++ b/bm_dos.c @@ -126,7 +126,7 @@ cleartoeol() int vgetc() { - return ((char)bioskey(0)); + return ((char)bioskey(0)); } diff --git a/bm_unix.c b/bm_unix.c index dd5c92f..4ae043f 100644 --- a/bm_unix.c +++ b/bm_unix.c @@ -7,10 +7,11 @@ * 2010-06-02 V 1.3.4 * 2013-08-22 V 1.4.0 * 2019-10-09 V 1.4.1 + * 2025-07-19 V 1.5.0 * * NOTE: Edit this file with tabstop=4 ! * - * Copyright 1996-2019 by Gerhard Buergmann + * Copyright 1996-2025 by Gerhard Buergmann * gerhard@puon.at * * This program is free software; you can redistribute it and/or modify it @@ -64,8 +65,7 @@ putchr(char ch) #else int -putchr(ch) - int ch; +putchr(int ch) {return putchar(ch);} #endif @@ -116,7 +116,7 @@ initterm() no_intty = tcgetattr(fileno(stdin), &ostate); tcgetattr(fileno(stderr), &ostate); - + nstate = ostate; if (!no_tty) { ostate.c_lflag &= ~(ICANON|ECHO); @@ -143,8 +143,7 @@ reset_tty() void -sig(sig) - int sig; +sig(int sig) { reset_tty(); printf("\r\n"); @@ -156,12 +155,15 @@ sig(sig) * doshell() - run a command or an interactive shell */ void -doshell(cmd) - char *cmd; +doshell(char *cmd) { int ret; #ifndef DJGPP +#ifdef __STDC__ + char *getenv(const char *); +#else char *getenv(); +#endif char *shell; char cline[128]; #endif @@ -277,10 +279,7 @@ vgetc() * Copy contents of memory (with possible overlapping). */ char * -memmove(s1, s2, n) - char *s1; - char *s2; - size_t n; +memmove(char *s1, char *s2, size_t n) { bcopy(s2, s1, n); return(s1); diff --git a/bmore.1 b/bmore.1 index fb82611..89ac7fe 100644 --- a/bmore.1 +++ b/bmore.1 @@ -1,4 +1,4 @@ -.TH BMORE 1 "8 Feb 2022" +.TH BMORE 1 "24 May 2025" .SH NAME bmore \- browse through a binary file .SH SYNOPSIS @@ -77,7 +77,7 @@ except that a header is printed before each file in a series. .SH OPTIONS .TP .B \-a -ASCII mode: no hex representation of the contents. Non printable +ASCII mode: no hex representation of the contents. Non printable characters are displayed as a dot (.) .TP .B \-c @@ -232,7 +232,7 @@ in the file remains unchanged. Regular expressions can be edited using erase and kill characters. Erasing back past the first column cancels the search command. .TP -.B \' +.B ' Single quote. Go to the point from which the last search started. If no search has been performed in the current file, go to the beginning of the file. diff --git a/bmore.c b/bmore.c index fa6b809..49231b8 100644 --- a/bmore.c +++ b/bmore.c @@ -9,8 +9,9 @@ * 2013-08-23 V 1.4.0 * 2019-01-22 V 1.4.1 * 2023-03-06 V 1.4.2 + * 2025-07-19 V 1.5.0 * - * Copyright 1990-2023 by Gerhard Buergmann + * Copyright 1990-2025 by Gerhard Buergmann * gerhard@puon.at * * NOTE: Edit this file with tabstop=4 ! @@ -113,9 +114,7 @@ usage() int -main(argc, argv) - int argc; - char *argv[]; +main(int argc, char *argv[]) { int ch, ch1; int colon = 0, last_ch = 0; @@ -141,7 +140,7 @@ main(argc, argv) #endif poi = strrchr(argv[0], DELIM); - + if (poi) strncpy(progname, ++poi, 9); else strncpy(progname, argv[0], 9); strtok(progname, "."); @@ -177,7 +176,7 @@ main(argc, argv) break; case 'r': r_flag++; break; - default: + default: usage(); } i++; @@ -340,7 +339,7 @@ main(argc, argv) fclose(curr_file); reset_tty(); exit(exval); - case ':' : + case ':' : switch (colon) { case 'f': prompt = 0; @@ -449,7 +448,7 @@ main(argc, argv) bytepos = screen_home; to_print = maxy; break; - case '\\': + case '\\': if (ascii_flag) { bmbeep(); break; @@ -460,13 +459,13 @@ main(argc, argv) if (rdline(ch, sstring)) break; } case 'n': /**** Search Next ****/ - case 'N': + case 'N': bmsearch(ch); /* to_print--; */ break; - case '\'': + case '\'': if (no_intty) { bmbeep(); } else { @@ -493,7 +492,7 @@ main(argc, argv) break; } while ((ch1 = getc(help_file)) != EOF) - putchar(ch1); + putchar(ch1); fclose(help_file); to_print = 0; break; @@ -502,13 +501,13 @@ main(argc, argv) if (!no_intty) { cleartoeol(); if (ch == 'v') { - sprintf(string, "bvi +%lu %s", - (unsigned long)(screen_home + + sprintf(string, "bvi +%lu %s", + (unsigned long)(screen_home + (maxy + 1) / 2 * out_len), name); } else { if (precount < 1) precount = bytepos - screen_home; sprintf(string, "bvi -b %lu -s %lu %s", - (unsigned long)screen_home, + (unsigned long)screen_home, (unsigned long)precount, name); } doshell(string); @@ -533,9 +532,7 @@ main(argc, argv) int -rdline(ch, sstring) - int ch; - char *sstring; +rdline(int ch, char *sstring) { int i = 0; int ch1 = 0; @@ -587,8 +584,7 @@ rdline(ch, sstring) void -do_next(n) - int n; +do_next(int n) { if (numfiles) { if (n == 1 && file_nr == numfiles) { @@ -614,8 +610,7 @@ do_next(n) int -open_file(name) - char *name; +open_file(char *name) { struct stat buf; @@ -636,9 +631,7 @@ open_file(name) void -putline(buf, num) - char *buf; - int num; +putline(char *buf, int num) { int print_pos; unsigned char ch; @@ -649,31 +642,31 @@ putline(buf, num) if (!ascii_flag) { for (print_pos = 0; print_pos < num; print_pos++) { ch = buf[print_pos]; - PRINTF("%02X ", ch); + PRINTF("%02X ", ch); } for (; print_pos < out_len; print_pos++) { - PRINTF(" "); + PRINTF(" "); } PRINTF(" "); } - + // ASCII section for (print_pos = 0; print_pos < num; print_pos++) { ++bytepos; ch = buf[print_pos]; if ((ch > 31) && (ch < 127)) { - PRINTF("%c", ch); + PRINTF("%c", ch); } else { if (r_flag) { if ((ch & 128) && ((ch > 159) && (ch < 255))) { if (!no_tty) highlight(); - PRINTF("%c", ch & 127); + PRINTF("%c", ch & 127); if (!no_tty) normal(); } else { - PRINTF("."); + PRINTF("."); } } else { - PRINTF("."); + PRINTF("."); } } } @@ -689,13 +682,12 @@ putline(buf, num) int -printout(lns) - int lns; +printout(int lns) { int c, num; int doub = 0; static int flag; - + if (c_flag) { clearscreen(); } @@ -755,9 +747,7 @@ nextchar() void -pushback(n, where) - int n; - char *where; +pushback(int n, char *where) { if (cnt) memmove(cmdbuf + n, cmdbuf, n); memcpy(cmdbuf, where, n); @@ -774,8 +764,7 @@ pushback(n, where) * 1 found */ int -bmregexec(scan) - char *scan; +bmregexec(char *scan) { char *act; int count, test; @@ -869,7 +858,7 @@ bmregexec(scan) pushback(1, --act); l--; } - } else { /* ".*" */ + } else { /* ".*" */ do { if ((test = nextchar()) == -1) return -5; *act++ = test; @@ -893,10 +882,7 @@ bmregexec(scan) int -sbracket(start, scan, count) - int start; - char *scan; - int count; +sbracket(int start, char *scan, int count) { if (*scan++ == '^') { if (!memchr(scan, start, --count)) return 0; @@ -908,8 +894,7 @@ sbracket(start, scan, count) void -bmsearch(ch) - int ch; +bmsearch(int ch) { int i; @@ -961,8 +946,7 @@ emsg(string); void -emsg(s) - char *s; +emsg(char *s) { putchar('\r'); cleartoeol(); diff --git a/bmore.h b/bmore.h index 2ebd4bf..e33439a 100644 --- a/bmore.h +++ b/bmore.h @@ -7,7 +7,7 @@ * 1999-08-21 V 1.2.0 final * 2000-05-31 V 1.3.0 beta * 2000-10-04 V 1.3.0 final - * 2002-01-16 V 1.3.1 + * 2002-01-16 V 1.3.1 * 2003-02-20 V 1.3.2 * 2010-03-28 V 1.3.4 * 2019-01-22 V 1.4.1 @@ -43,7 +43,7 @@ #if defined(__MSDOS__) && !defined(DJGPP) # include "patchlev.h" # include "dosconf.h" -# include +# include # include # include #else @@ -51,21 +51,21 @@ # include "config.h" # include # if defined HAVE_NCURSESW_CURSES_H -# include -# include +# include +# include # elif defined HAVE_NCURSESW_H -# include +# include # elif defined HAVE_NCURSES_CURSES_H -# include +# include # elif defined HAVE_NCURSES_H -# include +# include # elif defined HAVE_CURSES_H -# include +# include # else -# error "SysV or X/Open-compatible Curses header file required" +# error "SysV or X/Open-compatible Curses header file required" # endif # if HAVE_TERM_H -# include +# include # endif #endif @@ -136,7 +136,7 @@ extern int no_tty, no_intty; -#ifdef ANSI +#if defined(ANSI) || defined(__STDC__) void initterm(void), set_tty(void), reset_tty(void); void cleartoeol(void), clearscreen(void), highlight(void); void normal(void), bmbeep(void), home(void), sig(int); diff --git a/bvi.1 b/bvi.1 index 3c3b00f..3ac9cce 100644 --- a/bvi.1 +++ b/bvi.1 @@ -1,8 +1,8 @@ .rn '' }` -''' $RCSfile$$Revision$$Date$ -''' -''' $Log$ -''' +.\" $RCSfile$$Revision$$Date$ +.\" +.\" $Log$ +.\" .de Sh .br .if t .Sp @@ -31,12 +31,12 @@ .fi .. -''' -''' -''' Set up \*(-- to give an unbreakable dash; -''' string Tr holds user defined translation string. -''' Bell System Logo is used as a dummy character. -''' +.\" +.\" +.\" Set up \*(-- to give an unbreakable dash; +.\" string Tr holds user defined translation string. +.\" Bell System Logo is used as a dummy character. +.\" .tr \(*W-|\(bv\*(Tr .ie n \{\ .ds -- \(*W- @@ -45,10 +45,10 @@ .if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch .ds L" "" .ds R" "" -''' \*(M", \*(S", \*(N" and \*(T" are the equivalent of -''' \*(L" and \*(R", except that they are used on ".xx" lines, -''' such as .IP and .SH, which do another additional levels of -''' double-quote interpretation +.\" \*(M", \*(S", \*(N" and \*(T" are the equivalent of +.\" \*(L" and \*(R", except that they are used on ".xx" lines, +.\" such as .IP and .SH, which do another additional levels of +.\" double-quote interpretation .ds M" """ .ds S" """ .ds N" """"" @@ -79,9 +79,9 @@ 'br\} .\" If the F register is turned on, we'll generate .\" index entries out stderr for the following things: -.\" TH Title +.\" TH Title .\" SH Header -.\" Sh Subsection +.\" Sh Subsection .\" Ip Item .\" X<> Xref (embedded .\" Of course, you have to process the output yourself @@ -93,7 +93,7 @@ .nr % 0 .rr F .\} -.TH BVI 1 "BVI Version 1.4.2" "8/Feb/2022" "User Commands" +.TH BVI 1 "BVI Version 1.5.0" "31/May/2025" "User Commands" .IX Title "BVI 1" .UC .IX Name "bvi, bview - visual display editor for binary files" @@ -194,7 +194,7 @@ bvi, bview \- visual editor for binary files .SH "VERSION" .IX Header "VERSION" -bvi-1.4.1 +bvi-1.5.0 .SH "SYNOPSIS" .IX Header "SYNOPSIS" \fBbvi\fR\ \ \ [\fB\-R\fR]\ [\fB\-c\fR\ \fIcmd\fR]\ [\fB\-f\fR\ \fIscript\fR]\ [\fB\-s\fR\ \fIskip\fR]\ [\fB\-e\fR\ \fIend\fR]\ [\fB\-n\fR\ \fIlength\fR]\ \fIfile\fR... @@ -203,10 +203,10 @@ bvi-1.4.1 .IX Header "OPTIONS" .Ip "\fIfile\fR..." 4 .IX Item "\fIfile\fR..." -A list of filenames. The first one will be the current file and -will be read +A list of filenames. The first one will be the current file and +will be read into the buffer. The cursor will be positioned on the first line of -the buffer. You can get to the other files with the ":next" command. +the buffer. You can get to the other files with the ":next" command. .Ip "\fB\-R\fR" 4 .IX Item "\fB\-R\fR" \*(L"Readonly": The readonly flag is set for all the files, @@ -261,7 +261,7 @@ The byte offset (extreme left), the hex pane (middle), and an ascii pane (right) which shows as printable characters those bytes in the hex pane. On an 80 column terminal there will be sixteen hex values -and their ASCII values on each screen line. +and their ASCII values on each screen line. Note that (as one would expect) the first byte has the offset \*(L'0\*(R' (zero). .PP You can toggle between the hex and ascii windows with the tab key (TAB). @@ -270,10 +270,10 @@ position (offset) within the file. .PP No \*(L"lines\*(R" concept: Files are treated as one long stream of bytes. The characters -\*(L"newline\*(R" and \*(L"carriage return\*(R" are not special, id est they +\*(L"newline\*(R" and \*(L"carriage return\*(R" are not special, id est they never mark the end of lines. Therefore the lines on the screen do not represent lines in the usual way. Data is broken across screen lines -arbitarily. +arbitrarily. As a consequence there are no commands in bvi from ex or vi that are based on line numbers, eg \*(L"dd\*(R", \*(L"yy\*(R", \*(L'C\*(R', \*(L'S\*(R', \*(L'o\*(R', \*(L'O\*(R'. This also changes the meaning of \*(L"range\*(R" before the \*(L":write\*(R" command @@ -313,13 +313,13 @@ using these meta sequences: .Ve Additional search commands: Similar to the text search commands there are additional hex-search -functions \*(L'\e\*(R' and \*(L'#\*(R' which allow to search for any byte value. +functions \*(L'\e\*(R' and \*(L'#\*(R' which allow one to search for any byte value. Example: \*(L"\e62 76 69\*(R" will search for the string \*(L"bvi\*(R". Spaces between hex value are optional, so searching for \*(L"6775636B6573\*(R" will find \*(L"guckes\*(R". .PP Changing the length of data (insertion, deletion) moves the data to other addresses; -this is bad for many cases (eg. databases, program files) and is +this is bad for many cases (eg. databases, program files) and is thus disabled by default. You can enable this commands by typing .PP \f(CW :set memmove\fR @@ -334,11 +334,11 @@ Use ESC (escape) to cancel a partial (uncompleted) command. .PP Input Mode: .PP -Input is treated as replacement of current characters or +Input is treated as replacement of current characters or (after the end of the file) is appended to the current file. This mode is entered from command mode by typing one of \*(L'i\*(R', \*(L'I\*(R', \*(L'A\*(R', \*(L'r\*(R', or \*(L'R\*(R'. -You can enter the characters from the keyboard (in the ASCII window) or +You can enter the characters from the keyboard (in the ASCII window) or hexadecimal values (in the HEX window). Type TAB to switch between these two windows. Type ESC to finish the current input and return to command mode. @@ -346,8 +346,8 @@ Type CTRL\-C to cancel current command abnormally. .PP Command line mode (Last Line Mode or : mode): .PP -Similar to vi, this mode is entered by typing one of the -characters +Similar to vi, this mode is entered by typing one of the +characters : / ? \e # ! The command is terminated and executed by typing a carriage return; to cancel a partially typed command, type @@ -439,10 +439,10 @@ used within the following description of commands. You can insert/append/change bytes in ASCII/binary/decimal/ hexadecimal or octal representation. You can enter several (screen) lines of input. A line with only a period (.) in it -will terminate the command. You must not type in values greater +will terminate the command. You must not type in values greater than a byte value. This causes an abandonment of the command. Pressing the CR key does not insert a newline \- character into -the file. If you use ASCII mode you can use the special characters +the file. If you use ASCII mode you can use the special characters \en, \er, \et and \e0. .PP .Vb 3 @@ -507,7 +507,7 @@ the file. If you use ASCII mode you can use the special characters `\fIx\fR move cursor to mark \fIx\fR in HEX section \*(L'\*(R' move cursor to previous context in ASCII section `` move cursor to previous context in HEX section - + \fBLine positioning:\fR H jump to first line on screen ("top") L jump to last line on screen ("low") @@ -554,7 +554,7 @@ the file. If you use ASCII mode you can use the special characters rx replace current bte with char \*(L'x\*(R' R enter replace mode; for all subsequent input, the current byte is overwritten with the next - input character; leave replace mode with ESC. + input character; leave replace mode with ESC. .PP \fBMiscellaneous Operations:\fR TAB toggle between ASCII and HEX section @@ -583,8 +583,8 @@ the file. If you use ASCII mode you can use the special characters \& columns cm=16 on an 80 character wide terminal \& ignorecase noic Ignores letter case in searching \& magic nomagic Makes . [ * special in patterns -\& memmove nomm enables insert and delete commands -\& offset of=0 adds an offset to the diplayed addresses +\& memmove nomm enables insert and delete commands +\& offset of=0 adds an offset to the displayed addresses \& readonly noro If set, write fails unless you use ! after command \& reverse nore display otherwise-printable characters with their \& high bit set as reverse video @@ -606,7 +606,7 @@ bvi was developed by Gerhard Buergmann, Vienna, Austria \fIgerhard@puon.at\fR .SH "WWW" .IX Header "WWW" -Bvi\ Homepage:\ \ http://bvi.sourceforge.net/ +Bvi\ Homepage:\ \ https://bvi.sourceforge.net/ Vi\ Pages:\ \ \ \ \ \ http://www.guckes.net/vi/clones.php3 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ (all\ about\ Vi\ and\ its\ clones) .SH "FILES" @@ -614,9 +614,6 @@ Vi\ Pages:\ \ \ \ \ \ http://www.guckes.net/vi/clones.php3 \fI\ $HOME/.bvirc\fR\ \ \ \ \ \ \ \ \ \ editor\ startup\ file .BR \fI\ ./.bvirc\fR\ \ \ \ \ \ \ \ \ \ \ \ \ \ editor\ startup\ file -.SH "BUGS" -.IX Header "BUGS" -Bvi does not update the screen when the terminal changes its size. .SH "SEE ALSO" .IX Header "SEE ALSO" \fIbmore\fR\|(1), \fIvi\fR\|(1), \fIstrings\fR\|(1), \fIascii\fR\|(5) diff --git a/bvi.c b/bvi.c index 9c5e443..50574ff 100644 --- a/bvi.c +++ b/bvi.c @@ -2,7 +2,7 @@ * * 1996-02-28 V 1.0.0 * 1999-01-27 V 1.1.0 - * 1999-04-22 V 1.1.1 + * 1999-04-22 V 1.1.1 * 1999-07-01 V 1.2.0 beta * 1999-10-22 V 1.2.0 final * 2000-05-10 V 1.3.0 alpha @@ -14,10 +14,11 @@ * 2014-10-07 V 1.4.0 * 2019-10-12 V 1.4.1 * 2023-03-06 V 1.4.2 + * 2025-07-19 V 1.5.0 * * NOTE: Edit this file with tabstop=4 ! * - * Copyright 1996-2023 by Gerhard Buergmann + * Copyright 1996-2025 by Gerhard Buergmann * gerhard@puon.at * * This program is free software; you can redistribute it and/or modify it @@ -44,55 +45,56 @@ #endif -char *copyright = "(C) GPL 1996-2023 by Gerhard Buergmann"; +char *copyright = "(C) GPL 1996-2025 by Gerhard Buergmann"; jmp_buf env; /* context for `longjmp' function */ -int loc; -int maxx, maxy, x, xx, y; -int screen, status, statsize; +int loc; +int maxx, maxy, x, xx, y; +int screen, status, statsize; off_t size; -PTR mem = NULL; -PTR curpos; -PTR maxpos; -PTR pagepos; -PTR spos; +PTR mem = NULL; +PTR curpos; +PTR maxpos; +PTR pagepos; +PTR spos; char *name = NULL; char *shell; char string[MAXCMD+1]; char cmdstr[MAXCMD+1] = ""; FILE *Ausgabe_Datei; -int edits = 0; -int AnzAdd, Anzahl, Anzahl3; +int edits = 0; +int AnzAdd, Anzahl, Anzahl3; off_t filesize, memsize, undosize; - +int statusflag = 1; +int space = 2; long precount = -1; -int block_flag = 0; +int block_flag = 0; off_t block_begin, block_end, block_size; char **files; /* list of input files */ -int numfiles; /* number of input files */ -int curfile; /* number of the current file */ +int numfiles; /* number of input files */ +int curfile; /* number of the current file */ -int arrnum = 0; +int arrnum = 0; char numarr[MAXCMD+1]; /* string for collecting number */ char rep_buf[BUFFER]; -PTR current; -PTR last_motion; -PTR current_start; -PTR undo_start; +PTR current; +PTR last_motion; +PTR current_start; +PTR undo_start; off_t undo_count; off_t yanked = 0L; char *yank_buf = NULL; char *undo_buf = NULL; char *fname_buf = NULL; -PTR markbuf[26]; +PTR markbuf[26]; char addr_form[15]; @@ -100,8 +102,8 @@ char *nobytes = "No bytes@in the buffer"; static char progname[8]; static char line[MAXCMD+1]; -static int mark; -static int wrstat = 1; +static int mark; +static int wrstat = 1; void @@ -117,9 +119,7 @@ usage() int -main(argc, argv) - int argc; - char *argv[]; +main(int argc, char *argv[]) { int ch; int lflag; @@ -248,7 +248,7 @@ main(argc, argv) break; case BLOCK_BEGIN|BLOCK_END|BLOCK_LEN: if (block_end - block_begin != block_size + 1) { - fprintf(stderr, "Ambigous block data\n"); + fprintf(stderr, "Ambiguous block data\n"); exit(1); } break; @@ -267,7 +267,9 @@ main(argc, argv) maxy = LINES; if (params[P_LI].flags & P_CHANGED) maxy = P(P_LI); P(P_SS) = maxy / 2; + /* We do not set P(P_LI) and P(P_CM) anymore, because 0 means "auto" P(P_LI) = maxy; + */ maxy--; keypad(stdscr, TRUE); scrollok(stdscr, TRUE); @@ -275,21 +277,21 @@ main(argc, argv) cbreak(); noecho(); - /* address column width */ - /* default is 8 + 2 blanks */ - /* if block_begin has 8 hex digits or more */ - /* reserve 1 hex digit more than required */ - char tmp[sizeof(block_begin) * 2 + 3]; - AnzAdd = sprintf(tmp, "%llX", (long long unsigned)block_begin) + 1; - if (AnzAdd < 8) - AnzAdd = 8; - if (AnzAdd > sizeof(block_begin) * 2) - AnzAdd = sizeof(block_begin) * 2; - sprintf(addr_form, "%%0%dllX ", AnzAdd); - AnzAdd = sprintf(tmp, addr_form, block_begin); + /* address column width */ + /* default is 8 + 2 blanks */ + /* if block_begin has 8 hex digits or more */ + /* reserve 1 hex digit more than required */ + char tmp[sizeof(block_begin) * 2 + 3]; + AnzAdd = sprintf(tmp, "%llX", (long long unsigned)block_begin) + 1; + if (AnzAdd < 8) AnzAdd = 8; + if (AnzAdd > sizeof(block_begin) * 2) AnzAdd = sizeof(block_begin) * 2; + sprintf(addr_form, "%%0%dllX ", AnzAdd); + AnzAdd = sprintf(tmp, addr_form, block_begin); - Anzahl = ((COLS - AnzAdd - 1) / 16) * 4; + Anzahl = ((COLS - AnzAdd - space) / 16) * 4; + /* P(P_CM) = Anzahl; + */ maxx = Anzahl * 4 + AnzAdd + 1; Anzahl3 = Anzahl * 3; statsize = 35; @@ -310,7 +312,7 @@ main(argc, argv) if (*cmdstr != '\0') docmdline(cmdstr); msg(fname_buf); - + /* main loop */ do { setjmp(env); @@ -328,6 +330,10 @@ main(argc, argv) else precount = -1; lflag = arrnum = 0; + if (statusflag == 0) { + statusflag = 1; + clearstr(); + } switch (ch) { case '^': x = AnzAdd; loc = HEX; @@ -426,7 +432,7 @@ main(argc, argv) x = AnzAdd - 1 + Anzahl3 + Anzahl; loc = ASCII; } break; - case ':' : clearstr(); + case ':' : clearstr(); addch(ch); refresh(); getcmdstr(cmdstr, 1); @@ -467,6 +473,18 @@ main(argc, argv) fileinfo(name); wrstat = 0; break; + case KEY_RESIZE: + if (P(P_CM) == 0) { + Anzahl = ((COLS - AnzAdd - space) / 4); + maxx = Anzahl * 4 + AnzAdd + 1; + Anzahl3 = Anzahl * 3; + status = Anzahl3 + Anzahl - statsize; + } + if (P(P_LI) == 0) { + screen = Anzahl * (maxy - 1); + maxy = LINES - 1; + P(P_SS) = maxy / 2; + } case BVICTRL('L'): /*** REDRAW SCREEN ***/ new_screen(); break; @@ -491,9 +509,9 @@ main(argc, argv) break; case ';': do_ft(0, 0); break; - case 'F': - case 'f': - case 't': + case 'F': + case 'f': + case 't': case 'T': do_ft(ch, 0); break; case 'G': last_motion = current; @@ -501,10 +519,10 @@ main(argc, argv) if ((precount < P(P_OF)) || (precount - P(P_OF)) > (filesize - 1L)) { beep(); - } else { + } else { setpage((PTR)(mem + precount - P(P_OF))); } - } else { + } else { setpage((PTR)(mem + filesize - 1L)); } break; @@ -735,8 +753,7 @@ main(argc, argv) off_t -calc_size(arg) - char *arg; +calc_size(char *arg) { off_t val; extern int errno; @@ -756,13 +773,13 @@ calc_size(arg) switch (*poi) { case 'k': case 'K': val *= 1024; - break; + break; case 'm': case 'M': val *= 1048576; - break; + break; case 'g': - case 'G': val *= 1024*1024*1024LL; - break; + case 'G': val *= 1024*1024*1024LL; + break; case '\0': break; default: usage(); } @@ -787,9 +804,7 @@ trunc_cur() int -do_append(count, buf) - off_t count; - char *buf; +do_append(off_t count, char *buf) { if (filesize + count > memsize) { if (enlarge(count + 100L)) return 1; @@ -806,8 +821,7 @@ do_append(count, buf) void -do_tilde(count) - off_t count; +do_tilde(off_t count) { if (filesize == 0L) return; undo_start = current; @@ -893,10 +907,7 @@ do_undo() void -do_over(loc, n, buf) - PTR loc; - off_t n; - PTR buf; +do_over(PTR loc, off_t n, PTR buf) { if (n < 1L) { emsg(nobytes); @@ -918,10 +929,7 @@ do_over(loc, n, buf) void -do_put(loc, n, buf) - PTR loc; - off_t n; - PTR buf; +do_put(PTR loc, off_t n, PTR buf) { if (n < 1L) { emsg(nobytes); @@ -949,8 +957,7 @@ do_put(loc, n, buf) /* argument sig not used, because only SIGINT will be catched */ void -jmpproc(sig) - int sig; +jmpproc(int sig) { if (P(P_EB)) beep(); repaint(); @@ -961,8 +968,7 @@ jmpproc(sig) off_t -range(ch) - int ch; +range(int ch) { int ch1; long count; @@ -1033,7 +1039,7 @@ range(ch) - (off_t)P(P_OF)) > (filesize - 1L)) { beep(); return 0; - } else { + } else { if (mem + count < current) { return(mem + count - current); } else { @@ -1051,9 +1057,9 @@ range(ch) } end_addr = markbuf[mark - 'a']; if (end_addr == NULL) { - beep(); + beep(); return 0; - } + } if (end_addr < current) { return(end_addr - current); } else { diff --git a/bvi.h b/bvi.h index bc96547..978846c 100644 --- a/bvi.h +++ b/bvi.h @@ -13,10 +13,11 @@ * 2014-10-01 V 1.4.0 * 2019-01-28 V 1.4.1 * 2023-03-07 V 1.4.2 + * 2025-05-24 V 1.5.0 * * NOTE: Edit this file with tabstop=4 ! * - * Copyright 1996-2023 by Gerhard Buergmann + * Copyright 1996-2025 by Gerhard Buergmann * gerhard@puon.at * * This program is free software; you can redistribute it and/or modify it @@ -46,8 +47,8 @@ #if defined(__MSDOS__) && !defined(DJGPP) # include "patchlev.h" # include "dosconf.h" -# include "doscur.h" -# include +# include "doscur.h" +# include #else # include "patchlevel.h" # include "config.h" @@ -129,14 +130,14 @@ # define ANSI # define PTR char huge * # define off_t long -# define DELIM '\\' -# define strncasecmp strnicmp -# define strcasecmp stricmp +# define DELIM '\\' +# define strncasecmp strnicmp +# define strcasecmp stricmp # define memcpy d_memcpy # define memmove d_memmove #else # define PTR char * -# define DELIM '/' +# define DELIM '/' #endif #define MAXCMD 255 @@ -164,27 +165,27 @@ extern char search_pat[]; extern long hl_spat; extern char pattern[]; extern char rep_buf[]; -extern int maxx, maxy, x, y; -extern int filemode, loc; -extern int edits, new; -extern int AnzAdd; -extern int Anzahl, Anzahl3; -extern int addr_flag; -extern int ignore_case, magic; -extern int screen, status, statsize; -extern PTR mem; -extern PTR maxpos; -extern PTR pagepos; -extern PTR undo_start; -extern PTR current_start; -extern PTR curpos; -extern PTR current; -extern PTR start_addr; -extern PTR end_addr; +extern int maxx, maxy, x, y; +extern int filemode, loc; +extern int edits, new; +extern int AnzAdd; +extern int Anzahl, Anzahl3; +extern int addr_flag; +extern int ignore_case, magic; +extern int screen, status, statsize; +extern PTR mem; +extern PTR maxpos; +extern PTR pagepos; +extern PTR undo_start; +extern PTR current_start; +extern PTR curpos; +extern PTR current; +extern PTR start_addr; +extern PTR end_addr; extern char *name, cmdstr[]; extern off_t filesize, memsize; -extern PTR markbuf[]; -extern PTR last_motion; +extern PTR markbuf[]; +extern PTR last_motion; extern off_t undo_count; extern off_t yanked; extern off_t undosize; @@ -192,14 +193,16 @@ extern char *copyright, *notfound; extern char *terminal; extern char *undo_buf; extern char *yank_buf; -extern int repl_count; +extern int repl_count; extern char string[]; extern char *shell; extern char *poi; -extern int smode; -extern int again; +extern int smode; +extern int again; extern int block_flag; extern off_t block_begin, block_end, block_size; +extern int statusflag; +extern int space; #ifndef S_ISDIR /* POSIX 1003.1 file type tests. */ #define S_ISDIR(m) ((m & 0170000) == 0040000) /* directory */ @@ -214,7 +217,7 @@ extern off_t block_begin, block_end, block_size; void d_memmove(PTR, PTR, off_t); #endif -#ifdef ANSI +#if defined(ANSI) || defined(__STDC__) off_t alloc_buf(off_t, char **), yd_addr(void); off_t range(int); void do_dot(void), do_exit(void), do_shell(void), do_undo(void); @@ -223,26 +226,26 @@ extern off_t block_begin, block_end, block_size; void do_mark(int, PTR), badcmd(char *), movebyte(void); void docmdline(char *), do_over(PTR, off_t, PTR), do_put(PTR, off_t, PTR); void jmpproc(int), printline(PTR, int); - int addfile(char *); - PTR bregexec(PTR, char *); - int chk_comm(int); - int doecmd(char *, int); - int do_append(off_t, char *), do_logic(int, char *); - int do_delete(off_t, PTR); - int doset(char *); - int do_substitution(int, char *, PTR, PTR); - int hexchar(void); - int outmsg(char *); - int save_chk(char *, char *, char *, int); - PTR searching(int, char *, PTR, PTR, int); - PTR wordsearch(PTR, char); - PTR backsearch(PTR, char); - PTR fsearch(PTR, PTR, char *); - PTR fsearch_end(PTR, PTR, char *, PTR *); - PTR rsearch(PTR, PTR, char *); - PTR end_word(PTR); - PTR calc_addr(char **, PTR); - PTR do_ft(int, int); + int addfile(char *); + PTR bregexec(PTR, char *); + int chk_comm(int); + int doecmd(char *, int); + int do_append(off_t, char *), do_logic(int, char *); + int do_delete(off_t, PTR); + int doset(char *); + int do_substitution(int, char *, PTR, PTR); + int hexchar(void); + int outmsg(char *); + int save_chk(char *, char *, char *, int); + PTR searching(int, char *, PTR, PTR, int); + PTR wordsearch(PTR, char); + PTR backsearch(PTR, char); + PTR fsearch(PTR, PTR, char *); + PTR fsearch_end(PTR, PTR, char *, PTR *); + PTR rsearch(PTR, PTR, char *); + PTR end_word(PTR); + PTR calc_addr(char **, PTR); + PTR do_ft(int, int); char *patcpy(char *, char *, char); void setpage(PTR), msg(char *), emsg(char *), smsg(char *); void usage(void), bvi_init(char *), statpos(void), setcur(void); @@ -253,43 +256,43 @@ extern off_t block_begin, block_end, block_size; off_t edit(int), load(char *); off_t calc_size(char *); int ascii_comp(char *, char *), hex_comp(char *, char *); - int cur_forw(int), cur_back(void); - int lineout(void), save(char *, PTR, PTR, int); - int at_least(char *, char *, int); - int vgetc(void), xpos(void), enlarge(off_t); - int getcmdstr(char *, int), read_rc(char *); - int wait_return(int); + int cur_forw(int), cur_back(void); + int lineout(void), save(char *, PTR, PTR, int); + int at_least(char *, char *, int); + int vgetc(void), xpos(void), enlarge(off_t); + int getcmdstr(char *, int), read_rc(char *); + int wait_return(int); #else - int addfile(); + int addfile(); off_t alloc_buf(), yd_addr(); off_t range(); off_t calc_size(); void do_mark(), badcmd(), movebyte(); void do_back(), do_ins_chg(); void jmpproc(), printline(); - int chk_comm(); + int chk_comm(); void docmdline(), do_over(), do_put(); - int doecmd(); + int doecmd(); void do_dot(), do_exit(), do_shell(), do_undo(); void do_tilde(), trunc_cur(); - int do_append(), do_logic(); - int do_delete(); - int doset(); - int do_substitution(); - int hexchar(); - int outmsg(); - int save_chk(); - PTR searching(); - PTR wordsearch(); - PTR backsearch(); + int do_append(), do_logic(); + int do_delete(); + int doset(); + int do_substitution(); + int hexchar(); + int outmsg(); + int save_chk(); + PTR searching(); + PTR wordsearch(); + PTR backsearch(); /* int bregexec(); */ - PTR bregexec(); - PTR fsearch(); - PTR fsearch_end(); - PTR rsearch(); - PTR end_word(); - PTR calc_addr(); - PTR do_ft(); + PTR bregexec(); + PTR fsearch(); + PTR fsearch_end(); + PTR rsearch(); + PTR end_word(); + PTR calc_addr(); + PTR do_ft(); char *patcpy(); void setpage(), msg(), emsg(), smsg(); void usage(), bvi_init(), statpos(), setcur(); @@ -299,9 +302,9 @@ extern off_t block_begin, block_end, block_size; void quit(), sysemsg(), do_z(), stuffin(); off_t edit(), load(); int ascii_comp(), hex_comp(); - int cur_forw(), cur_back(); - int lineout(), save(), at_least(), read_rc(); - int getcmdstr(), enlarge(); - int vgetc(), xpos(); - int wait_return(); + int cur_forw(), cur_back(); + int lineout(), save(), at_least(), read_rc(); + int getcmdstr(), enlarge(); + int vgetc(), xpos(); + int wait_return(); #endif diff --git a/comm.c b/comm.c index 72c0a47..51079ec 100644 --- a/comm.c +++ b/comm.c @@ -8,17 +8,18 @@ * 1999-09-10 V 1.2.0 final * 2000-03-03 V 1.3.0 beta * 2000-07-15 V 1.3.0 final - * 2001-10-10 V 1.3.1 + * 2001-10-10 V 1.3.1 * 2003-07-04 V 1.3.2 * 2005-08-17 V 1.3.3 * 2010-06-02 V 1.3.4 * 2014-01-28 V 1.4.0 * 2019-01-27 V 1.4.1 * 2023-03-06 V 1.4.2 + * 2025-07-19 V 1.5.0 * * NOTE: Edit this file with tabstop=4 ! * - * Copyright 1996-2023 by Gerhard Buergmann + * Copyright 1996-2025 by Gerhard Buergmann * gerhard@puon.at * * This program is free software; you can redistribute it and/or modify it @@ -72,8 +73,8 @@ static char *c_argv[9]; char *nowrtmsg = "No write@since last change (:%s! overrides)"; char *morefiles = "more files@to edit"; -char *ambigous = "Ambigous|Too many file names"; -char *ambvalue = "Ambigous|Too many values"; +char *ambigous = "Ambiguous|Too many file names"; +char *ambvalue = "Ambiguous|Too many values"; char *extra = "Extra chars|Extra characters at end of command"; char *noaddr = "No address allowed@on this command"; char *noval = "No value@for binary operation"; @@ -98,8 +99,7 @@ static char oldbuf[CMDSZ + 3]; /** for :!! command **/ * the environment variable "BVIINIT" (or eventually .bvirc). */ void -docmdline(cmdline) - char *cmdline; +docmdline(char *cmdline) { char buff[CMDSZ]; char cmdbuf[CMDSZ]; @@ -286,22 +286,22 @@ docmdline(cmdline) if ((c_argv[c_argc] = strtok(cmd, " \t")) != NULL) c_argc++; while ((c_argv[c_argc] = strtok(NULL, " \t")) != NULL) c_argc++; - if (c_argc > 1) { + if (c_argc > 1) { emsg(ambigous); return; } if (c_argc == 1) { - /* change '%' to Filename */ - while ((p = strchr(c_argv[0], '%')) != NULL && *(p-1) != '\\') { - if (name == NULL) { - emsg("No filename@to substitute for %"); - return; - } - *p = '\0'; - strcpy (oldbuf, c_argv[0]); - strcat (oldbuf, name); - strcat (oldbuf, p + 1); + /* change '%' to Filename */ + while ((p = strchr(c_argv[0], '%')) != NULL && *(p-1) != '\\') { + if (name == NULL) { + emsg("No filename@to substitute for %"); + return; + } + *p = '\0'; + strcpy (oldbuf, c_argv[0]); + strcat (oldbuf, name); + strcat (oldbuf, p + 1); c_argv[0] = oldbuf; - } + } } if (name == NULL && c_argc != 0) name = strdup(c_argv[0]); if (force) { @@ -629,11 +629,7 @@ yd_addr() /*********** Save file if not read only ********************/ int -save_chk(fname, start, end, flags) - char *fname; - char *start; - char *end; - int flags; +save_chk(char *fname, char *start, char *end, int flags) { if (P(P_RO)) { sprintf(string, "\"%s\" File is read only", name); @@ -657,9 +653,7 @@ do_exit() int -doecmd(arg, force) - char *arg; - int force; +doecmd(char *arg, int force) { char *tmp; @@ -722,33 +716,34 @@ clearstr() /**** displays an error message *****/ void -emsg(s) - char *s; +emsg(char *s) { int cnt; - int stchar; + /* + int stchar; - if (P(P_EB)) beep(); if (P(P_MO)) { stchar = statsize; } else { stchar = 0; } - + */ + if (P(P_EB)) beep(); + statusflag = 0; clearstr(); attrset(A_REVERSE); cnt = outmsg(s); attrset(A_NORMAL); - if (cnt >= (maxx - stchar)) { - addch('\n'); - wait_return(TRUE); } + if (cnt >= (maxx)) { + // addch('\n'); + wait_return(TRUE); + } } /*** System error message *****/ void -sysemsg(s) - char *s; +sysemsg(char *s) { char string[256]; @@ -764,8 +759,7 @@ sysemsg(s) /*** displays mode if showmode set *****/ void -smsg(s) - char *s; +smsg(char *s) { if (P(P_MO)) { msg(s); @@ -776,30 +770,30 @@ smsg(s) /************* displays s on status line *****************/ void -msg(s) - char *s; +msg(char *s) { + /* int stchar; if (P(P_MO)) { stchar = statsize; } else { stchar = 0; - } + }o*/ + statusflag = 0; clearstr(); - if (outmsg(s) >= (maxx - stchar)) { - addch('\n'); + if (outmsg(s) >= maxx) { + // addch('\n'); wait_return(TRUE); } } int -outmsg(s) - char *s; +outmsg(char *s) { char *poi; - int cnt = 0; + int cnt = 0; move(maxy, 0); poi = strchr(s, '|'); @@ -811,7 +805,7 @@ outmsg(s) cnt++; } } else { - if (poi) poi++; + if (poi) poi++; else poi = s; while (*poi) { if (*poi == '@') addch(' '); @@ -828,8 +822,7 @@ outmsg(s) * */ int -wait_return(flag) - int flag; +wait_return(int flag) { int c; @@ -852,8 +845,7 @@ wait_return(flag) int -chk_comm(flag) - int flag; +chk_comm(int flag) { if ((flag & NO_ADDR) && (addr_flag > 0)) { emsg(noaddr); return 1; } diff --git a/config.guess b/config.guess index 69188da..48a6846 100644 --- a/config.guess +++ b/config.guess @@ -1,10 +1,10 @@ #! /bin/sh # Attempt to guess a canonical system name. -# Copyright 1992-2023 Free Software Foundation, Inc. +# Copyright 1992-2024 Free Software Foundation, Inc. # shellcheck disable=SC2006,SC2268 # see below for rationale -timestamp='2023-01-01' +timestamp='2024-07-27' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -47,7 +47,7 @@ me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] -Output the configuration name of the system \`$me' is run on. +Output the configuration name of the system '$me' is run on. Options: -h, --help print this help, then exit @@ -60,13 +60,13 @@ version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. -Copyright 1992-2023 Free Software Foundation, Inc. +Copyright 1992-2024 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" -Try \`$me --help' for more information." +Try '$me --help' for more information." # Parse command line while test $# -gt 0 ; do @@ -102,8 +102,8 @@ GUESS= # temporary files to be created and, as you can see below, it is a # headache to deal with in a portable fashion. -# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still -# use `HOST_CC' if defined, but it is deprecated. +# Historically, 'CC_FOR_BUILD' used to be named 'HOST_CC'. We still +# use 'HOST_CC' if defined, but it is deprecated. # Portable tmp directory creation inspired by the Autoconf team. @@ -123,7 +123,7 @@ set_cc_for_build() { dummy=$tmp/dummy case ${CC_FOR_BUILD-},${HOST_CC-},${CC-} in ,,) echo "int x;" > "$dummy.c" - for driver in cc gcc c89 c99 ; do + for driver in cc gcc c17 c99 c89 ; do if ($driver -c -o "$dummy.o" "$dummy.c") >/dev/null 2>&1 ; then CC_FOR_BUILD=$driver break @@ -155,6 +155,9 @@ Linux|GNU|GNU/*) set_cc_for_build cat <<-EOF > "$dummy.c" + #if defined(__ANDROID__) + LIBC=android + #else #include #if defined(__UCLIBC__) LIBC=uclibc @@ -162,6 +165,8 @@ Linux|GNU|GNU/*) LIBC=dietlibc #elif defined(__GLIBC__) LIBC=gnu + #elif defined(__LLVM_LIBC__) + LIBC=llvm #else #include /* First heuristic to detect musl libc. */ @@ -169,6 +174,7 @@ Linux|GNU|GNU/*) LIBC=musl #endif #endif + #endif EOF cc_set_libc=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'` eval "$cc_set_libc" @@ -459,7 +465,7 @@ case $UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION in UNAME_RELEASE=`uname -v` ;; esac - # Japanese Language versions have a version number like `4.1.3-JL'. + # Japanese Language versions have a version number like '4.1.3-JL'. SUN_REL=`echo "$UNAME_RELEASE" | sed -e 's/-/_/'` GUESS=sparc-sun-sunos$SUN_REL ;; @@ -628,7 +634,8 @@ EOF sed 's/^ //' << EOF > "$dummy.c" #include - main() + int + main () { if (!__power_pc()) exit(1); @@ -712,7 +719,8 @@ EOF #include #include - int main () + int + main () { #if defined(_SC_KERNEL_BITS) long bits = sysconf(_SC_KERNEL_BITS); @@ -904,7 +912,7 @@ EOF fi ;; *:FreeBSD:*:*) - UNAME_PROCESSOR=`/usr/bin/uname -p` + UNAME_PROCESSOR=`uname -p` case $UNAME_PROCESSOR in amd64) UNAME_PROCESSOR=x86_64 ;; @@ -976,7 +984,27 @@ EOF GUESS=$UNAME_MACHINE-unknown-minix ;; aarch64:Linux:*:*) - GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + set_cc_for_build + CPU=$UNAME_MACHINE + LIBCABI=$LIBC + if test "$CC_FOR_BUILD" != no_compiler_found; then + ABI=64 + sed 's/^ //' << EOF > "$dummy.c" + #ifdef __ARM_EABI__ + #ifdef __ARM_PCS_VFP + ABI=eabihf + #else + ABI=eabi + #endif + #endif +EOF + cc_set_abi=`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^ABI' | sed 's, ,,g'` + eval "$cc_set_abi" + case $ABI in + eabi | eabihf) CPU=armv8l; LIBCABI=$LIBC$ABI ;; + esac + fi + GUESS=$CPU-unknown-linux-$LIBCABI ;; aarch64_be:Linux:*:*) UNAME_MACHINE=aarch64_be @@ -1042,6 +1070,15 @@ EOF k1om:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; + kvx:Linux:*:*) + GUESS=$UNAME_MACHINE-unknown-linux-$LIBC + ;; + kvx:cos:*:*) + GUESS=$UNAME_MACHINE-unknown-cos + ;; + kvx:mbr:*:*) + GUESS=$UNAME_MACHINE-unknown-mbr + ;; loongarch32:Linux:*:* | loongarch64:Linux:*:*) GUESS=$UNAME_MACHINE-unknown-linux-$LIBC ;; @@ -1197,7 +1234,7 @@ EOF GUESS=$UNAME_MACHINE-pc-sysv4.2uw$UNAME_VERSION ;; i*86:OS/2:*:*) - # If we were able to find `uname', then EMX Unix compatibility + # If we were able to find 'uname', then EMX Unix compatibility # is probably installed. GUESS=$UNAME_MACHINE-pc-os2-emx ;; @@ -1338,7 +1375,7 @@ EOF GUESS=ns32k-sni-sysv fi ;; - PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort + PENTIUM:*:4.0*:*) # Unisys 'ClearPath HMP IX 4000' SVR4/MP effort # says GUESS=i586-unisys-sysv4 ;; @@ -1560,6 +1597,9 @@ EOF *:Unleashed:*:*) GUESS=$UNAME_MACHINE-unknown-unleashed$UNAME_RELEASE ;; + *:Ironclad:*:*) + GUESS=$UNAME_MACHINE-unknown-ironclad + ;; esac # Do we have a guess based on uname results? @@ -1583,6 +1623,7 @@ cat > "$dummy.c" < header file. */ #undef HAVE_FCNTL_H diff --git a/config.sub b/config.sub index de4259e..4aaae46 100644 --- a/config.sub +++ b/config.sub @@ -1,10 +1,10 @@ #! /bin/sh # Configuration validation subroutine script. -# Copyright 1992-2023 Free Software Foundation, Inc. +# Copyright 1992-2024 Free Software Foundation, Inc. -# shellcheck disable=SC2006,SC2268 # see below for rationale +# shellcheck disable=SC2006,SC2268,SC2162 # see below for rationale -timestamp='2023-01-21' +timestamp='2024-05-27' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -76,13 +76,13 @@ Report bugs and patches to ." version="\ GNU config.sub ($timestamp) -Copyright 1992-2023 Free Software Foundation, Inc. +Copyright 1992-2024 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" -Try \`$me --help' for more information." +Try '$me --help' for more information." # Parse command line while test $# -gt 0 ; do @@ -120,7 +120,6 @@ case $# in esac # Split fields of configuration type -# shellcheck disable=SC2162 saved_IFS=$IFS IFS="-" read field1 field2 field3 field4 <&2 + echo "Invalid configuration '$1': more than four components" >&2 exit 1 ;; *-*-*-*) @@ -142,10 +141,21 @@ case $1 in # parts maybe_os=$field2-$field3 case $maybe_os in - nto-qnx* | linux-* | uclinux-uclibc* \ - | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* \ - | netbsd*-eabi* | kopensolaris*-gnu* | cloudabi*-eabi* \ - | storm-chaos* | os2-emx* | rtmk-nova* | managarm-*) + cloudabi*-eabi* \ + | kfreebsd*-gnu* \ + | knetbsd*-gnu* \ + | kopensolaris*-gnu* \ + | linux-* \ + | managarm-* \ + | netbsd*-eabi* \ + | netbsd*-gnu* \ + | nto-qnx* \ + | os2-emx* \ + | rtmk-nova* \ + | storm-chaos* \ + | uclinux-gnu* \ + | uclinux-uclibc* \ + | windows-* ) basic_machine=$field1 basic_os=$maybe_os ;; @@ -160,8 +170,12 @@ case $1 in esac ;; *-*) - # A lone config we happen to match not fitting any pattern case $field1-$field2 in + # Shorthands that happen to contain a single dash + convex-c[12] | convex-c3[248]) + basic_machine=$field2-convex + basic_os= + ;; decstation-3100) basic_machine=mips-dec basic_os= @@ -169,28 +183,88 @@ case $1 in *-*) # Second component is usually, but not always the OS case $field2 in - # Prevent following clause from handling this valid os + # Do not treat sunos as a manufacturer sun*os*) basic_machine=$field1 basic_os=$field2 ;; + # Manufacturers + 3100* \ + | 32* \ + | 3300* \ + | 3600* \ + | 7300* \ + | acorn \ + | altos* \ + | apollo \ + | apple \ + | atari \ + | att* \ + | axis \ + | be \ + | bull \ + | cbm \ + | ccur \ + | cisco \ + | commodore \ + | convergent* \ + | convex* \ + | cray \ + | crds \ + | dec* \ + | delta* \ + | dg \ + | digital \ + | dolphin \ + | encore* \ + | gould \ + | harris \ + | highlevel \ + | hitachi* \ + | hp \ + | ibm* \ + | intergraph \ + | isi* \ + | knuth \ + | masscomp \ + | microblaze* \ + | mips* \ + | motorola* \ + | ncr* \ + | news \ + | next \ + | ns \ + | oki \ + | omron* \ + | pc533* \ + | rebel \ + | rom68k \ + | rombug \ + | semi \ + | sequent* \ + | siemens \ + | sgi* \ + | siemens \ + | sim \ + | sni \ + | sony* \ + | stratus \ + | sun \ + | sun[234]* \ + | tektronix \ + | tti* \ + | ultra \ + | unicom* \ + | wec \ + | winbond \ + | wrs) + basic_machine=$field1-$field2 + basic_os= + ;; zephyr*) basic_machine=$field1-unknown basic_os=$field2 ;; - # Manufacturers - dec* | mips* | sequent* | encore* | pc533* | sgi* | sony* \ - | att* | 7300* | 3300* | delta* | motorola* | sun[234]* \ - | unicom* | ibm* | next | hp | isi* | apollo | altos* \ - | convergent* | ncr* | news | 32* | 3600* | 3100* \ - | hitachi* | c[123]* | convex* | sun | crds | omron* | dg \ - | ultra | tti* | harris | dolphin | highlevel | gould \ - | cbm | ns | masscomp | apple | axis | knuth | cray \ - | microblaze* | sim | cisco \ - | oki | wec | wrs | winbond) - basic_machine=$field1-$field2 - basic_os= - ;; *) basic_machine=$field1 basic_os=$field2 @@ -271,26 +345,6 @@ case $1 in basic_machine=arm-unknown basic_os=cegcc ;; - convex-c1) - basic_machine=c1-convex - basic_os=bsd - ;; - convex-c2) - basic_machine=c2-convex - basic_os=bsd - ;; - convex-c32) - basic_machine=c32-convex - basic_os=bsd - ;; - convex-c34) - basic_machine=c34-convex - basic_os=bsd - ;; - convex-c38) - basic_machine=c38-convex - basic_os=bsd - ;; cray) basic_machine=j90-cray basic_os=unicos @@ -713,15 +767,26 @@ case $basic_machine in vendor=dec basic_os=tops20 ;; - delta | 3300 | motorola-3300 | motorola-delta \ - | 3300-motorola | delta-motorola) + delta | 3300 | delta-motorola | 3300-motorola | motorola-delta | motorola-3300) cpu=m68k vendor=motorola ;; - dpx2*) + # This used to be dpx2*, but that gets the RS6000-based + # DPX/20 and the x86-based DPX/2-100 wrong. See + # https://oldskool.silicium.org/stations/bull_dpx20.htm + # https://www.feb-patrimoine.com/english/bull_dpx2.htm + # https://www.feb-patrimoine.com/english/unix_and_bull.htm + dpx2 | dpx2[23]00 | dpx2[23]xx) cpu=m68k vendor=bull - basic_os=sysv3 + ;; + dpx2100 | dpx21xx) + cpu=i386 + vendor=bull + ;; + dpx20) + cpu=rs6000 + vendor=bull ;; encore | umax | mmax) cpu=ns32k @@ -836,18 +901,6 @@ case $basic_machine in next | m*-next) cpu=m68k vendor=next - case $basic_os in - openstep*) - ;; - nextstep*) - ;; - ns2*) - basic_os=nextstep2 - ;; - *) - basic_os=nextstep3 - ;; - esac ;; np1) cpu=np1 @@ -936,14 +989,13 @@ case $basic_machine in ;; *-*) - # shellcheck disable=SC2162 saved_IFS=$IFS IFS="-" read cpu vendor <&2 + echo "Invalid configuration '$1': machine '$cpu-$vendor' not recognized" 1>&2 exit 1 ;; esac @@ -1306,11 +1491,12 @@ esac # Decode manufacturer-specific aliases for certain operating systems. -if test x$basic_os != x +if test x"$basic_os" != x then # First recognize some ad-hoc cases, or perhaps split kernel-os, or else just # set os. +obj= case $basic_os in gnu/linux*) kernel=linux @@ -1325,7 +1511,6 @@ case $basic_os in os=`echo "$basic_os" | sed -e 's|nto-qnx|qnx|'` ;; *-*) - # shellcheck disable=SC2162 saved_IFS=$IFS IFS="-" read kernel os <&2 + fi + ;; *) - echo Invalid configuration \`"$1"\': OS \`"$os"\' not recognized 1>&2 + echo "Invalid configuration '$1': OS '$os' not recognized" 1>&2 + exit 1 + ;; +esac + +case $obj in + aout* | coff* | elf* | pe*) + ;; + '') + # empty is fine + ;; + *) + echo "Invalid configuration '$1': Machine code format '$obj' not recognized" 1>&2 + exit 1 + ;; +esac + +# Here we handle the constraint that a (synthetic) cpu and os are +# valid only in combination with each other and nowhere else. +case $cpu-$os in + # The "javascript-unknown-ghcjs" triple is used by GHC; we + # accept it here in order to tolerate that, but reject any + # variations. + javascript-ghcjs) + ;; + javascript-* | *-ghcjs) + echo "Invalid configuration '$1': cpu '$cpu' is not valid with os '$os$obj'" 1>&2 exit 1 ;; esac # As a final step for OS-related things, validate the OS-kernel combination # (given a valid OS), if there is a kernel. -case $kernel-$os in - linux-gnu* | linux-dietlibc* | linux-android* | linux-newlib* \ - | linux-musl* | linux-relibc* | linux-uclibc* | linux-mlibc* ) +case $kernel-$os-$obj in + linux-gnu*- | linux-android*- | linux-dietlibc*- | linux-llvm*- \ + | linux-mlibc*- | linux-musl*- | linux-newlib*- \ + | linux-relibc*- | linux-uclibc*- | linux-ohos*- ) ;; - uclinux-uclibc* ) + uclinux-uclibc*- | uclinux-gnu*- ) ;; - managarm-mlibc* | managarm-kernel* ) + managarm-mlibc*- | managarm-kernel*- ) ;; - -dietlibc* | -newlib* | -musl* | -relibc* | -uclibc* | -mlibc* ) + windows*-msvc*-) + ;; + -dietlibc*- | -llvm*- | -mlibc*- | -musl*- | -newlib*- | -relibc*- \ + | -uclibc*- ) # These are just libc implementations, not actual OSes, and thus # require a kernel. - echo "Invalid configuration \`$1': libc \`$os' needs explicit kernel." 1>&2 + echo "Invalid configuration '$1': libc '$os' needs explicit kernel." 1>&2 exit 1 ;; - -kernel* ) - echo "Invalid configuration \`$1': \`$os' needs explicit kernel." 1>&2 + -kernel*- ) + echo "Invalid configuration '$1': '$os' needs explicit kernel." 1>&2 exit 1 ;; - *-kernel* ) - echo "Invalid configuration \`$1': \`$kernel' does not support \`$os'." 1>&2 + *-kernel*- ) + echo "Invalid configuration '$1': '$kernel' does not support '$os'." 1>&2 exit 1 ;; - kfreebsd*-gnu* | kopensolaris*-gnu*) + *-msvc*- ) + echo "Invalid configuration '$1': '$os' needs 'windows'." 1>&2 + exit 1 ;; - vxworks-simlinux | vxworks-simwindows | vxworks-spe) + kfreebsd*-gnu*- | knetbsd*-gnu*- | netbsd*-gnu*- | kopensolaris*-gnu*-) ;; - nto-qnx*) + vxworks-simlinux- | vxworks-simwindows- | vxworks-spe-) ;; - os2-emx) + nto-qnx*-) ;; - *-eabi* | *-gnueabi*) + os2-emx-) ;; - -*) + rtmk-nova-) + ;; + *-eabi*- | *-gnueabi*-) + ;; + none--*) + # None (no kernel, i.e. freestanding / bare metal), + # can be paired with an machine code file format + ;; + -*-) # Blank kernel with real OS is always fine. ;; - *-*) - echo "Invalid configuration \`$1': Kernel \`$kernel' not known to work with OS \`$os'." 1>&2 + --*) + # Blank kernel and OS with real machine code file format is always fine. + ;; + *-*-*) + echo "Invalid configuration '$1': Kernel '$kernel' not known to work with OS '$os'." 1>&2 exit 1 ;; esac @@ -1826,7 +2273,7 @@ case $vendor in *-riscix*) vendor=acorn ;; - *-sunos*) + *-sunos* | *-solaris*) vendor=sun ;; *-cnk* | *-aix*) @@ -1896,7 +2343,7 @@ case $vendor in ;; esac -echo "$cpu-$vendor-${kernel:+$kernel-}$os" +echo "$cpu-$vendor${kernel:+-$kernel}${os:+-$os}${obj:+-$obj}" exit # Local variables: diff --git a/configure.ac b/configure.ac index be763c7..1a57146 100644 --- a/configure.ac +++ b/configure.ac @@ -12,13 +12,13 @@ dnl On SunOS4 systems you have to use the /usr/5bin/cc compiler dnl to get the SYSV curses library: case "$host_os" in sunos4*) - AC_MSG_RESULT("using /usr/5bin/cc") - CC="/usr/5bin/cc" - ac_objext="o" - ;; + AC_MSG_RESULT("using /usr/5bin/cc") + CC="/usr/5bin/cc" + ac_objext="o" + ;; *) - AC_PROG_CC - ;; + AC_PROG_CC + ;; esac @@ -26,11 +26,11 @@ dnl Some curses specials dnl Solaris needs for tputs 'putc(char)' instead of 'putc(int)' case "$host_os" in solaris*) - CPPFLAGS="${CPPFLAGS} -D_MSE_INT_H" - AC_DEFINE(NEED_PUTC_CHAR) - ;; + CPPFLAGS="${CPPFLAGS} -D_MSE_INT_H" + AC_DEFINE(NEED_PUTC_CHAR) + ;; hpux9*) DEFS=${DEFS-"-DMINICURSES"} - ;; + ;; esac @@ -65,21 +65,21 @@ AC_ARG_WITH(ncurses, AC_CHECK_HEADER([ncurses.h],[ AC_SEARCH_LIBS([initscr], [ncurses], [ AC_DEFINE(HAVE_NCURSES_H) - AC_SEARCH_LIBS([tputs], [tinfo])],[ + AC_SEARCH_LIBS([tputs], [tinfo])],[ AC_SEARCH_LIBS([initscr], [curses],[ AC_DEFINE(HAVE_CURSES_H) AC_SEARCH_LIBS([tputs], [tinfo])],[ - AC_MSG_ERROR([bvi requires a curses library])])]) - ],[ + AC_MSG_ERROR([bvi requires a curses library])])]) + ],[ AC_CHECK_HEADER([curses.h],[ - AC_SEARCH_LIBS([initscr], [curses], [ - AC_DEFINE(HAVE_CURSES_H)],[ - AC_MSG_ERROR([bvi requires a curses library])])],[ + AC_SEARCH_LIBS([initscr], [curses], [ + AC_DEFINE(HAVE_CURSES_H)],[ + AC_MSG_ERROR([bvi requires a curses library])])],[ AC_CHECK_HEADER([ncursesw/curses.h], [ - AC_SEARCH_LIBS([initscr], [ncursesw], [ - AC_DEFINE(HAVE_NCURSESW_CURSES_H)],[ - AC_MSG_ERROR([bvi requires a curses library])])],[ - AC_MSG_ERROR([bvi requires a curses library])])])]) + AC_SEARCH_LIBS([initscr], [ncursesw], [ + AC_DEFINE(HAVE_NCURSESW_CURSES_H)],[ + AC_MSG_ERROR([bvi requires a curses library])])],[ + AC_MSG_ERROR([bvi requires a curses library])])])]) dnl Checks for typedefs, structures, and compiler characteristics. dnl AC_TYPE_SIZE_T diff --git a/dosio.c b/dosio.c index 90cd281..e5d44a1 100644 --- a/dosio.c +++ b/dosio.c @@ -141,14 +141,14 @@ save(char *fname, PTR start, PTR end, int flags) if (!fname) { emsg("No file|No current filename"); return 0; - } + } if (stat(fname, &buf) == -1) { newstr = "[New file] "; - } else { - if (S_ISDIR(buf.st_mode)) { - sprintf(string, "\"%s\" Is a directory", fname); - msg(string); - return 0; + } else { + if (S_ISDIR(buf.st_mode)) { + sprintf(string, "\"%s\" Is a directory", fname); + msg(string); + return 0; } newstr = ""; } @@ -159,20 +159,20 @@ save(char *fname, PTR start, PTR end, int flags) return 0; } if (filemode == PARTIAL) { - if (block_read) { - filesize = block_read; - sprintf(string, "\"%s\" range %lu-%lu", fname, - (unsigned long)block_begin, - (unsigned long)(block_begin - 1 + filesize)); - if (lseek(fd, block_begin, SEEK_SET) < 0) { - sysemsg(fname); - return 0; - } - } else { - msg("Null range"); - return 0; - } - } else { + if (block_read) { + filesize = block_read; + sprintf(string, "\"%s\" range %lu-%lu", fname, + (unsigned long)block_begin, + (unsigned long)(block_begin - 1 + filesize)); + if (lseek(fd, block_begin, SEEK_SET) < 0) { + sysemsg(fname); + return 0; + } + } else { + msg("Null range"); + return 0; + } + } else { filesize = end - start + 1L; sprintf(string, "\"%s\" %s%lu@bytes", fname, newstr, (long)filesize); } @@ -228,7 +228,7 @@ load(char *fname) } else if (filemode == REGULAR) { memsize = buf.st_size + 100; } else { - memsize = 1000; + memsize = 1000; } if (farcoreleft() < memsize) { @@ -255,18 +255,18 @@ load(char *fname) filesize += (off_t)n; } while (filesize < buf.st_size); if ((filesize == 0) { - sprintf(string, "\"%s\" No such range: %lu-%lu", fname, - (unsigned long)block_begin, (unsigned long)(block_end)); - } else { - sprintf(string, "\"%s\" range %lu-%lu", fname, - (unsigned long)block_begin, - (unsigned long)(block_begin + filesize - 1)); - } - filemode = PARTIAL; - block_read = filesize; - msg(string); - P(P_OF) = block_begin; - params[P_OF].flags |= P_CHANGED; + sprintf(string, "\"%s\" No such range: %lu-%lu", fname, + (unsigned long)block_begin, (unsigned long)(block_end)); + } else { + sprintf(string, "\"%s\" range %lu-%lu", fname, + (unsigned long)block_begin, + (unsigned long)(block_begin + filesize - 1)); + } + filemode = PARTIAL; + block_read = filesize; + msg(string); + P(P_OF) = block_begin; + params[P_OF].flags |= P_CHANGED; } } else if (filemode == REGULAR) { chunk = buf.st_size > 0xfffe ? 0xfffe : buf.st_size; diff --git a/edit.c b/edit.c index ee1a1a7..3e9d5fa 100644 --- a/edit.c +++ b/edit.c @@ -12,8 +12,9 @@ * 2006-04-05 V 1.3.3 alpha - binary representation * 2014-09-30 V 1.4.0 * 2019-10-12 V 1.4.1 + * 2025-07-19 V 1.5.0 * - * Copyright 1996-2019 by Gerhard Buergmann + * Copyright 1996-2025 by Gerhard Buergmann * gerhard@puon.at * * This program is free software; you can redistribute it and/or modify it @@ -63,8 +64,7 @@ static char *getcnext = NULL; * characters (for "." command) */ off_t -edit(mode) - int mode; +edit(int mode) { int ch, ch1; size_t len; @@ -117,7 +117,7 @@ edit(mode) setcur(); continue; } - if (ch == KEY_BACKSPACE + if (ch == KEY_BACKSPACE || ch == ASCII_DEL || ch == BVICTRL('H')) { if (count > 0) { @@ -286,8 +286,7 @@ escape: * else setpage() */ PTR -do_ft(ch, flag) - int ch, flag; +do_ft(int ch, int flag) { static int chi; static int chp = 1; @@ -298,7 +297,7 @@ do_ft(ch, flag) switch (ch) { /* case 1: beep(); - return NULL; no previous command + return NULL; no previous command case -1: if (chp == 'f' || chp == 't') dir = BACKWARD; else dir = FORWARD; break; @@ -364,8 +363,7 @@ do_ft(ch, flag) void -do_z(mode) - int mode; +do_z(int mode) { switch (mode) { case '.': while (y != maxy / 2) { @@ -401,8 +399,7 @@ do_z(mode) void -scrolldown(lns) - int lns; +scrolldown(int lns) { while (lns--) { if (maxpos >= (pagepos + Anzahl)) pagepos += Anzahl; @@ -414,8 +411,7 @@ scrolldown(lns) void -scrollup(lns) - int lns; +scrollup(int lns) { while (lns--) { if (mem <= (PTR)(pagepos - Anzahl)) pagepos -= Anzahl; @@ -459,13 +455,14 @@ setcur() void statpos() { - char bin_val [9]; + char bin_val [9]; unsigned char Char1; - int i; + int i; off_t bytepos; char string[MAXCMD+1], str[6]; - if (!P(P_MO)) return; + // if (!P(P_MO)) return; + if (!statusflag) return; bytepos = current - mem; if (bytepos >= filesize) { // mvaddstr(maxy, status, " "); @@ -483,11 +480,19 @@ statpos() } } bin_val[8] = '\0'; - - sprintf(string, "%08llX %s \\%03o 0x%02X %3d ", - (long long)(bytepos + P(P_OF)), bin_val, Char1, Char1, Char1); + attrset(A_BOLD); status = maxx - 1 - statsize; + if (status > 0) { + sprintf(string, "%08llX %s \\%03o 0x%02X %3d ", + (long long)(bytepos + P(P_OF)), bin_val, Char1, Char1, Char1); + } else { + sprintf(string, "%08llX %3d ", + (long long)(bytepos + P(P_OF)), Char1); + mvaddstr(maxy, 0, string); + attrset(A_NORMAL); + return; + } mvaddstr(maxy, status, string); if (isprint(Char1)) { @@ -521,10 +526,9 @@ statpos() } + void -printline(mempos, scpos) - PTR mempos; - int scpos; +printline(PTR mempos, int scpos) { PTR hl_start = 0; PTR hl_end = 0; @@ -544,44 +548,44 @@ printline(mempos, scpos) mv_pos = AnzAdd; *linbuf = '\0'; if (hl_spat) { - f_start = (mempos - Anzahl) < mem ? mem : (mempos - Anzahl); - f_end = mempos + (2 * Anzahl); - hl_start = fsearch_end(f_start, f_end, search_pat, &hl_end); + f_start = (mempos - Anzahl) < mem ? mem : (mempos - Anzahl); + f_end = mempos + (2 * Anzahl); + hl_start = fsearch_end(f_start, f_end, search_pat, &hl_end); } for (print_pos = 0; print_pos < Anzahl; print_pos++) { if (hl_spat) { - while (hl_start != NULL) { - if (hl_start < mempos) { - if (hl_end < mempos) { - f_start = hl_start + 1; - hl_start = fsearch_end(f_start, f_end, search_pat, &hl_end); - } else { - attrset(A_STANDOUT); /* start out highlighted */ - break; - } - } else if (hl_start >= mempos) { - break; - } - } - if (hl_start != NULL) { - if ((hl_start - mempos) == print_pos) { - mvaddstr(scpos, mv_pos, linbuf); - mv_pos = AnzAdd + (3 * print_pos); - *linbuf = '\0'; - attrset(A_STANDOUT); - } - if ((hl_end - mempos) == print_pos) { - mvaddstr(scpos, mv_pos, linbuf); - *linbuf = '\0'; - mv_pos = AnzAdd + (3 * print_pos); - f_start = hl_end; - hl_start = fsearch_end(f_start, f_end, search_pat, &hl_end); - if (f_start != hl_start) { - attrset(A_NORMAL); - } - } - } + while (hl_start != NULL) { + if (hl_start < mempos) { + if (hl_end < mempos) { + f_start = hl_start + 1; + hl_start = fsearch_end(f_start, f_end, search_pat, &hl_end); + } else { + attrset(A_STANDOUT); /* start out highlighted */ + break; + } + } else if (hl_start >= mempos) { + break; + } + } + if (hl_start != NULL) { + if ((hl_start - mempos) == print_pos) { + mvaddstr(scpos, mv_pos, linbuf); + mv_pos = AnzAdd + (3 * print_pos); + *linbuf = '\0'; + attrset(A_STANDOUT); + } + if ((hl_end - mempos) == print_pos) { + mvaddstr(scpos, mv_pos, linbuf); + *linbuf = '\0'; + mv_pos = AnzAdd + (3 * print_pos); + f_start = hl_end; + hl_start = fsearch_end(f_start, f_end, search_pat, &hl_end); + if (f_start != hl_start) { + attrset(A_NORMAL); + } + } + } } if (mempos + print_pos >= maxpos) { sprintf(tmpbuf, " "); @@ -609,10 +613,10 @@ printline(mempos, scpos) addstr(string); attrset(A_NORMAL); } else { - addstr("."); + addstr("."); } } else { - addstr("."); + addstr("."); } } } else { @@ -660,8 +664,7 @@ repaint() /***** redraw screen *********************/ /******* display an arbitrary address on screen *******/ void -setpage(addr) - PTR addr; +setpage(PTR addr) { if ((addr >= pagepos) && ((addr - pagepos) < screen)) { y = (addr - pagepos) / Anzahl; @@ -684,8 +687,7 @@ setpage(addr) int -cur_forw(check) - int check; +cur_forw(int check) { if (check) { if (current - mem >= filesize) { @@ -760,8 +762,7 @@ cur_back() void -fileinfo(fname) - char *fname; +fileinfo(char *fname) { off_t bytepos; char fstatus[MAXCMD]; @@ -788,8 +789,8 @@ fileinfo(fname) if (edits) strcat(string, "[Modified] "); if (filesize) { bytepos = (pagepos + y * Anzahl + xpos()) - mem + 1L; - sprintf(fstatus, "byte %llu of %llu --%llu%%--", - (unsigned long long)bytepos, + sprintf(fstatus, "byte %llu of %llu --%llu%%--", + (unsigned long long)bytepos, (unsigned long long)filesize, (unsigned long long)(bytepos * 100L / filesize)); strcat(string, fstatus); @@ -830,8 +831,7 @@ vgetc() void -stuffin(s) -char *s; +stuffin(char *s) { if (s == NULL) { /* clear the stuff buffer */ getcnext = NULL; @@ -846,9 +846,7 @@ char *s; void -do_back(n, start) - off_t n; - PTR start; +do_back(off_t n, PTR start) { if (start - n < mem) { beep(); @@ -870,9 +868,7 @@ do_back(n, start) int -do_delete(n, start) - off_t n; - PTR start; +do_delete(off_t n, PTR start) { if (n + start > maxpos) { beep(); @@ -902,10 +898,7 @@ do_delete(n, start) * The :insert, :append and :change command */ void -do_ins_chg(start, arg, mode) - PTR start; - char *arg; - int mode; +do_ins_chg(PTR start, char *arg, int mode) { int base; off_t buffer = BUFFER; @@ -945,22 +938,22 @@ do_ins_chg(start, arg, mode) if (base == 1) { /* ASCII */ while (*poi != '\0') { if (*poi == '\\') { - switch (*(++poi)) { - case 'n': val = '\n'; break; - case 'r': val = '\r'; break; - case 't': val = '\t'; break; - case '0': val = '\0'; break; - case '\\': val = '\\'; break; - default : val = '\\'; poi--; - } - poi++; + switch (*(++poi)) { + case 'n': val = '\n'; break; + case 'r': val = '\r'; break; + case 't': val = '\t'; break; + case '0': val = '\0'; break; + case '\\': val = '\\'; break; + default : val = '\\'; poi--; + } + poi++; } else { val = *poi++; } *(tempbuf + count++) = val; } } else { - while (isspace(cmdstr[strlen(cmdstr) - 1])) + while (isspace(cmdstr[strlen(cmdstr) - 1])) cmdstr[strlen(cmdstr) - 1] = '\0'; while (*poi != '\0') { val = strtol(poi, &epoi, base); @@ -993,7 +986,7 @@ do_ins_chg(start, arg, mode) case U_APPEND: if ((undo_count = alloc_buf(count, &undo_buf)) == 0L) { repaint(); - goto mfree; + goto mfree; } do_append((off_t)count, tempbuf); memcpy(undo_buf, tempbuf, count); @@ -1021,11 +1014,9 @@ clear_marks() void -do_mark(mark, addr) - int mark; - PTR addr; +do_mark(int mark, PTR addr) { - if (mark < 'a' || mark > 'z' || current >= maxpos) + if (mark < 'a' || mark > 'z' || current >= maxpos) return; markbuf[mark - 'a'] = addr; } diff --git a/io.c b/io.c index a34d8fc..b9c2741 100644 --- a/io.c +++ b/io.c @@ -12,10 +12,11 @@ * 2014-05-03 V 1.4.0 * 2019-01-27 V 1.4.1 * 2022-03-09 V 1.4.2 + * 2025-07-19 V 1.5.0 * * NOTE: Edit this file with tabstop=4 ! * - * Copyright 1996-2022 by Gerhard Buergmann + * Copyright 1996-2025 by Gerhard Buergmann * gerhard@puon.at * * This program is free software; you can redistribute it and/or modify it @@ -79,11 +80,7 @@ extern char *fname_buf; /*********** Save the patched file ********************/ int -save(fname, start, end, flags) - char *fname; - char *start; - char *end; - int flags; +save(char *fname, char *start, char *end, int flags) { int fd; char *string; @@ -167,8 +164,7 @@ save(fname, start, end, flags) /* loads a file, returns the filesize */ off_t -load(fname) - char *fname; +load(char *fname) { int fd = -1; //char *string; @@ -235,7 +231,7 @@ load(fname) params[P_RO].flags |= P_CHANGED; } } else { - sysemsg(fname); + sysemsg(fname); filemode = ERROR; } } @@ -333,12 +329,11 @@ load(fname) } -/* argument "dir" not used! +/* argument "dir" not used! * Needed for DOS version only */ void -bvi_init(dir) - char *dir; +bvi_init(char *dir) { char *initstr; char rcpath[MAXCMD]; @@ -352,7 +347,7 @@ bvi_init(dir) docmdline(initstr); return; } - + #ifdef DJGPP strcpy(rcpath, "c:"); strcpy(rcpath, dir); @@ -378,8 +373,7 @@ bvi_init(dir) int -enlarge(add) - off_t add; +enlarge(off_t add) { char *newmem; off_t savecur, savepag, savemax, saveundo; @@ -428,11 +422,10 @@ do_shell() #ifndef HAVE_STRDUP char * -strdup(s) - char *s; +strdup(char *s) { char *p; - size_t n; + size_t n; n = strlen(s) + 1; if ((p = (char *)malloc(n)) != NULL) @@ -447,10 +440,7 @@ strdup(s) * Copy contents of memory (with possible overlapping). */ char * -memmove(s1, s2, n) - char *s1; - char *s2; - size_t n; +memmove(char *s1, char *s2, size_t n) { bcopy(s2, s1, n); return(s1); @@ -459,9 +449,7 @@ memmove(s1, s2, n) off_t -alloc_buf(n, buffer) - off_t n; - char **buffer; +alloc_buf(off_t n, char **buffer) { if (*buffer == NULL) { *buffer = (char *)malloc(n); @@ -477,8 +465,7 @@ alloc_buf(n, buffer) int -addfile(fname) - char *fname; +addfile(char *fname) { int fd; off_t oldsize; diff --git a/macro.m4 b/macro.m4 index c28ed01..c8c0698 100644 --- a/macro.m4 +++ b/macro.m4 @@ -1,59 +1,59 @@ AC_CHECK_HEADER ( - [ncurses.h], - [ + [ncurses.h], + [ AC_SEARCH_LIBS ([initscr], [ncurses], - [ - AC_DEFINE(HAVE_NCURSES_H) - AC_SEARCH_LIBS([tputs], [tinfo]) - ],[ - AC_SEARCH_LIBS - ( - [initscr], [curses], + [ + AC_DEFINE(HAVE_NCURSES_H) + AC_SEARCH_LIBS([tputs], [tinfo]) + ],[ + AC_SEARCH_LIBS + ( + [initscr], [curses], [ - AC_DEFINE(HAVE_CURSES_H) - AC_SEARCH_LIBS([tputs], [tinfo]) + AC_DEFINE(HAVE_CURSES_H) + AC_SEARCH_LIBS([tputs], [tinfo]) ],[ - AC_MSG_ERROR([bvi requires a curses library]) + AC_MSG_ERROR([bvi requires a curses library]) ] ) - ] + ] ) - ],[ + ],[ AC_CHECK_HEADER ( - [curses.h], - [ - AC_SEARCH_LIBS + [curses.h], + [ + AC_SEARCH_LIBS + ( + [initscr], [curses], + [ + AC_DEFINE(HAVE_CURSES_H) + ],[ + AC_MSG_ERROR([bvi requires a curses library]) + ] + ) + ],[ + # statt: AC_MSG_ERROR([bvi requires a curses library]) + AC_CHECK_HEADER ( - [initscr], [curses], + [ncursesw/curses.h], [ - AC_DEFINE(HAVE_CURSES_H) + AC_SEARCH_LIBS + ( + [initscr], [curses], + [ + AC_DEFINE(HAVE_NCURSESW_CURSES_H) + ],[ + AC_MSG_ERROR([bvi requires a curses library]) + ] + ) ],[ - AC_MSG_ERROR([bvi requires a curses library]) + AC_MSG_ERROR([bvi requires a curses library]) ] ) - ],[ -# statt: AC_MSG_ERROR([bvi requires a curses library]) - AC_CHECK_HEADER - ( - [ncursesw/curses.h], - [ - AC_SEARCH_LIBS - ( - [initscr], [curses], - [ - AC_DEFINE(HAVE_NCURSESW_CURSES_H) - ],[ - AC_MSG_ERROR([bvi requires a curses library]) - ] - ) - ],[ - AC_MSG_ERROR([bvi requires a curses library]) - ] - ) - ] - ) - ] + ] + ) + ] ) diff --git a/patchlevel.h b/patchlevel.h index af30db7..2ed1b2c 100644 --- a/patchlevel.h +++ b/patchlevel.h @@ -1 +1 @@ -#define VERSION "1.4.2" +#define VERSION "1.5.0" diff --git a/re.c b/re.c index df6f9c2..cee506d 100644 --- a/re.c +++ b/re.c @@ -12,8 +12,9 @@ * 2013-08-24 V 1.4.0 * 2019-01-28 V 1.4.1 * 2023-03-07 V 1.4.2 + * 2025-07-19 V 1.5.0 * - * Copyright 1996-2023 by Gerhard Buergmann + * Copyright 1996-2025 by Gerhard Buergmann * gerhard@puon.at * * This program is free software; you can redistribute it and/or modify it @@ -32,11 +33,15 @@ /* You cannot use a common regexp subroutine, because \0 is a regular * character in a binary string ! */ - + #include "bvi.h" #include "set.h" +#ifdef __STDC__ +static int sbracket(int, char *, int); +#else static int sbracket(); +#endif char act_pat[MAXCMD]; /* found pattern */ char pattern[MAXCMD + 1]; @@ -48,9 +53,7 @@ char *emptyclass = "Bad character class|Empty byte class '[]' or '[^]' cannot ma PTR -bregexec(start, scan) - PTR start; - char *scan; +bregexec(PTR start, char *scan) { char *act; int count, test; @@ -125,10 +128,7 @@ bregexec(start, scan) static int -sbracket(start, scan, count) - int start; - char *scan; - int count; +sbracket(int start, char *scan, int count) { if (*scan++ == '^') { if (!memchr(scan, start, --count)) return 0; @@ -140,8 +140,7 @@ sbracket(start, scan, count) PTR -end_word(start) - PTR start; +end_word(PTR start) { PTR pos; @@ -155,9 +154,7 @@ end_word(start) /* wordsearch serves the 'W' and 'w' - command */ PTR -wordsearch(start, mode) - PTR start; - char mode; +wordsearch(PTR start, char mode) { PTR found; PTR pos; @@ -187,9 +184,7 @@ wordsearch(start, mode) /* backsearch serves the 'b' and 'B' command */ PTR -backsearch(start, mode) - PTR start; - char mode; +backsearch(PTR start, char mode) { PTR pos; int ccount; @@ -216,11 +211,7 @@ backsearch(start, mode) /* used by :s */ int -do_substitution(delim, line, startpos, endpos) - int delim; - char *line; - PTR startpos; - PTR endpos; +do_substitution(int delim, char *line, PTR startpos, PTR endpos) { int n; char *found; @@ -332,9 +323,9 @@ AGAIN: emsg(notfound); } else { if (P(P_TE)) - sprintf(string, "No match to %s", direct == FORWARD ? "BOTTOM" : "TOP"); + sprintf(string, "No match to %s", direct == FORWARD ? "BOTTOM" : "TOP"); else - sprintf(string, "Address search hit %s without matching pattern", + sprintf(string, "Address search hit %s without matching pattern", direct == FORWARD ? "BOTTOM" : "TOP"); emsg(string); } @@ -376,12 +367,7 @@ SKIP: * return address found */ PTR -searching(ch, line, startpos, endpos, flag) - int ch; - char *line; - PTR startpos; - PTR endpos; - int flag; +searching(int ch, char *line, PTR startpos, PTR endpos, int flag) { char *cmd = NULL; PTR found; @@ -455,9 +441,9 @@ searching(ch, line, startpos, endpos, flag) emsg(notfound); } else { if (P(P_TE)) { - sprintf(string, "No match to %s", sdir == FORWARD ? "BOTTOM" : "TOP"); + sprintf(string, "No match to %s", sdir == FORWARD ? "BOTTOM" : "TOP"); } else { - sprintf(string, "Address search hit %s without matching pattern", + sprintf(string, "Address search hit %s without matching pattern", sdir == FORWARD ? "BOTTOM" : "TOP"); } emsg(string); @@ -485,9 +471,7 @@ searching(ch, line, startpos, endpos, flag) * returns pointer to next character */ char * -patcpy(s1, s2, delim) - char *s1, *s2; - char delim; +patcpy(char *s1, char *s2, char delim) { while (*s2 != '\0' && *s2 != delim) { if (*s2 == '\\' && *(s2 + 1) == delim) s2++; @@ -500,14 +484,10 @@ patcpy(s1, s2, delim) PTR -fsearch_end(start, end, smem, s_end) +fsearch_end(PTR start, PTR end, char *smem, PTR *s_end) /* fsearch(start, end, smem) */ - PTR start; - PTR end; - char *smem; - PTR *s_end; { PTR spos; @@ -526,10 +506,7 @@ fsearch(start, end, smem) PTR -fsearch(start, end, smem) - PTR start; - PTR end; - char *smem; +fsearch(PTR start, PTR end, char *smem) { PTR s_end; return fsearch_end(start, end, smem, &s_end); @@ -537,10 +514,7 @@ fsearch(start, end, smem) PTR -rsearch(start, end, smem) - PTR start; - PTR end; - char *smem; +rsearch(PTR start, PTR end, char *smem) { PTR spos; @@ -560,9 +534,7 @@ rsearch(start, end, smem) * returns NULL on error or default_address, if nothing found */ PTR -calc_addr(pointer, def_addr) - char **pointer; - PTR def_addr; +calc_addr(char **pointer, PTR def_addr) { PTR addr; int ch, mark; diff --git a/recomp.c b/recomp.c index 1937b9c..e078689 100644 --- a/recomp.c +++ b/recomp.c @@ -6,8 +6,9 @@ * 2000-04-25 V 1.3.0 beta * 2000-07-12 V 1.3.0 final * 2019-01-28 V 1.4.1 + * 2025-07-19 V 1.5.0 * - * Copyright 1996-2019 by Gerhard Buergmann + * Copyright 1996-2025 by Gerhard Buergmann * gerhard@puon.at * * This program is free software; you can redistribute it and/or modify it @@ -26,7 +27,7 @@ /* You cannot use a common regexp subroutine, because \0 is a regular * character in a binary string ! */ - + #include "bvi.h" #include "set.h" @@ -46,9 +47,7 @@ extern char *emptyclass; * Compiling an ASCII sequence to a regex string */ int -ascii_comp(smem, pattern) - char *smem; - char *pattern; +ascii_comp(char *smem, char *pattern) { char *end; char *comp; @@ -167,9 +166,7 @@ ascii_comp(smem, pattern) * Compiling a hex expression to a regex string */ int -hex_comp(smem, pattern) - char *smem; - char *pattern; +hex_comp(char *smem, char *pattern) { char *end; char *comp; diff --git a/set.c b/set.c index 7f2707f..7a507ff 100644 --- a/set.c +++ b/set.c @@ -9,13 +9,14 @@ * 1999-07-02 V 1.2.0 beta * 1999-08-14 V 1.2.0 final * 2000-07-15 V 1.3.0 final - * 2001-10-10 V 1.3.1 + * 2001-10-10 V 1.3.1 * 2003-07-03 V 1.3.2 * 2010-06-02 V 1.2.4 * 2014-09-30 V 1.4.0 * 2019-01-22 V 1.4.1 + * 2025-07-19 V 1.5.0 * - * Copyright 1996-2019 by Gerhard Buergmann + * Copyright 1996-2025 by Gerhard Buergmann * gerhard@puon.at * * This program is free software; you can redistribute it and/or modify it @@ -34,46 +35,47 @@ #include "bvi.h" #include "set.h" -static int from_file = 0; +static int from_file = 0; static FILE *ffp; static char fbuf[MAXCMD+1]; static char buf[MAXCMD+1]; struct param params[] = { { "autowrite", "aw", FALSE, "", P_BOOL }, - { "columns", "cm", 16, "", P_NUM }, + { "columns", "cm", 0, "", P_NUM }, { "errorbells", "eb", FALSE, "", P_BOOL }, { "ignorecase", "ic", FALSE, "", P_BOOL }, - { "magic", "ma", TRUE, "", P_BOOL }, + { "magic", "ma", TRUE, "", P_BOOL }, { "memmove", "mm", FALSE, "", P_BOOL }, - { "offset", "of", 0, "", P_NUM }, + { "offset", "of", 0, "", P_NUM }, { "readonly", "ro", FALSE, "", P_BOOL }, - { "scroll", "scroll", 12, "", P_NUM }, + { "scroll", "scroll", 12, "", P_NUM }, { "showmode", "mo", TRUE, "", P_BOOL }, - { "term", "term", 0, "", P_TEXT }, - { "terse", "terse", FALSE, "", P_BOOL }, + { "term", "term", 0, "", P_TEXT }, + { "terse", "terse", FALSE, "", P_BOOL }, { "unixstyle", "us", FALSE, "", P_BOOL }, - { "window", "window", 25, "", P_NUM }, - { "wordlength", "wl", 4, "", P_NUM }, + { "window", "window", 0, "", P_NUM }, + { "wordlength", "wl", 4, "", P_NUM }, { "wrapscan", "ws", TRUE, "", P_BOOL }, - { "highlight", "hl", TRUE, "", P_BOOL }, - { "reverse", "re", FALSE, "", P_BOOL }, + { "highlight", "hl", TRUE, "", P_BOOL }, + { "reverse", "re", FALSE, "", P_BOOL }, #if defined(__MSDOS__) && !defined(DJGPP) - { "color", "co", 7, "", P_NUM }, + { "color", "co", 7, "", P_NUM }, #endif - { "", "", 0, "", 0, } /* end marker */ + { "", "", 0, "", 0, } /* end marker */ }; + int -doset(arg) - char *arg; /* parameter string */ +doset(char *arg) { - int i; + int i; char *s; - int did_window = FALSE; - int state = TRUE; /* new state of boolean parms. */ + int did_window = FALSE; + int state = TRUE; /* new state of boolean parms. */ char string[80]; + off_t val; if (arg == NULL) { showparms(FALSE); @@ -111,20 +113,38 @@ doset(arg) return 0; } if (!strcmp(params[i].fullname, "term")) { - emsg("Can't change type of terminal from within bvi"); + emsg("Can't change@type of terminal from within bvi"); return 1; } if (params[i].flags & P_NUM) { - if ((i == P_LI) || (i == P_OF)) did_window++; + if ((i == P_LI) || (i == P_OF) || (i == P_CM)) did_window++; if (arg[strlen(s)] != '=' || state == FALSE) { - sprintf(string, "Option %s is not a toggle", - params[i].fullname); + sprintf(string, "Option %s is not a toggle", params[i].fullname); emsg(string); return 1; } else { s = arg + strlen(s) + 1; - params[i].nvalue = strtoll(s, &s, 0); + val = strtoll(s, &s, 0); + if ((i == P_CM || i == P_LI) && (!strcmp("auto", s) || (val == 0))) { + if (i == P_CM) { + params[i].nvalue = 0; + Anzahl = ((COLS - AnzAdd - space) / 4); + } else { + params[i].nvalue = 0; + maxy = LINES - 1; + } + } else { + params[i].nvalue = val; + if (i == P_CM) { + Anzahl = val; + } else { + maxy = val; + } + } params[i].flags |= P_CHANGED; + if (i == P_LI) params[P_SS].nvalue = val / 2; + + #if defined(__MSDOS__) && !defined(DJGPP) if (i == P_CO) { textcolor(P(P_CO) & 0x07); @@ -134,22 +154,23 @@ doset(arg) } #endif if (i == P_CM) { + /* if (((COLS - AnzAdd - 1) / 4) >= P(P_CM)) { Anzahl = P(P_CM); } else { - Anzahl = P(P_CM) = ((COLS - AnzAdd - 1) / 4); + Anzahl = ((COLS - AnzAdd - 1) / 4); } - maxx = Anzahl * 4 + AnzAdd + 1; - Anzahl3 = Anzahl * 3; - status = Anzahl3 + Anzahl - 17; - screen = Anzahl * (maxy - 1); - did_window++; + */ + maxx = Anzahl * 4 + AnzAdd + 1; + Anzahl3 = Anzahl * 3; + status = Anzahl3 + Anzahl - statsize; + screen = Anzahl * (maxy - 1); stuffin("H"); /* set cursor at HOME */ } } } else { /* boolean */ if (arg[strlen(s)] == '=') { - emsg("Invalid set of boolean parameter"); + emsg("Invalid set@of boolean parameter"); return 1; } else { params[i].nvalue = state; @@ -169,7 +190,10 @@ doset(arg) } if (did_window) { + /* maxy = P(P_LI) - 1; + maxy = LINES - 1; + */ new_screen(); } @@ -179,28 +203,33 @@ doset(arg) /* show ALL parameters */ void -showparms(all) - int all; +showparms(int all) { struct param *p; - int n; + int n, i; + statusflag = 0; n = 2; + i = -1; msg("Parameters:\n"); for (p = ¶ms[0]; p->fullname[0] != '\0' ;p++) { + i++; if (!all && ((p->flags & P_CHANGED) == 0)) continue; - if (p->flags & P_BOOL) - sprintf(buf, " %s%s\n", - (p->nvalue ? " " : "no"), p->fullname); - else if (p->flags & P_TEXT) + if (p->flags & P_BOOL) { + sprintf(buf, " %s%s\n", (p->nvalue ? " " : "no"), p->fullname); + } else if (p->flags & P_TEXT) { sprintf(buf, " %s=%s\n", p->fullname, p->svalue); - else - sprintf(buf, " %s=%lld\n", p->fullname, (long long)p->nvalue); - + } else { + if ((p->nvalue == 0) && (i == P_CM || i == P_LI)) { + sprintf(buf, " %s=auto\n", p->fullname); + } else { + sprintf(buf, " %s=%lld\n", p->fullname, (long long)p->nvalue); + } + } msg(buf); n++; - if (n == params[P_LI].nvalue) { + if (n == maxy) { if (wait_return(FALSE)) return; n = 1; } @@ -211,8 +240,7 @@ showparms(all) /* reads the init file (.bvirc) */ int -read_rc(fn) - char *fn; +read_rc(char *fn) { int i; @@ -230,9 +258,7 @@ read_rc(fn) int -do_logic(mode, str) - int mode; - char *str; +do_logic(int mode, char *str) { int a, b; int value; @@ -289,13 +315,13 @@ do_logic(mode, str) b = a >> 8; a |= b; break; - case RROTATE: + case RROTATE: b = a << 8; a |= b; - a >>= value; + a >>= value; /* b = a << (8 - value); - a >>= value; + a >>= value; a |= b; */ break; @@ -303,7 +329,7 @@ do_logic(mode, str) break; case OR: a |= value; break; - case XOR: + case XOR: case NOT: a ^= value; break; case NEG: a ^= value; @@ -318,9 +344,7 @@ do_logic(mode, str) int -getcmdstr(p, x) - char *p; - int x; +getcmdstr(char *p, int x) { int c; int i, n; diff --git a/set.h b/set.h index 8995296..1abc28b 100644 --- a/set.h +++ b/set.h @@ -2,8 +2,8 @@ * * NOTE: Edit this file with tabstop=4 ! * - * Copyright 1996-2019 by Gerhard Buergmann - * Gerhard.Buergmann@puon.at + * Copyright 1996-2025 by Gerhard Buergmann + * gerhard@puon.at * * 1998-03-14 V 1.0.0 * 1999-01-14 V 1.1.0 @@ -14,6 +14,7 @@ * 2010-06-02 V 1.3.4 * 2013-08-23 V 1.4.0 * 2019-01-22 V 1.4.1 + * 2025-05-24 V 1.5.0 * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License as published by the @@ -34,7 +35,7 @@ struct param { char *shortname; /* permissible abbreviation */ off_t nvalue; char *svalue; - int flags; + int flags; }; extern struct param params[]; diff --git a/tags b/tags index 2f52151..d5989e2 100644 --- a/tags +++ b/tags @@ -1,551 +1,570 @@ !_TAG_FILE_FORMAT 2 /extended format; --format=1 will not append ;" to lines/ !_TAG_FILE_SORTED 1 /0=unsorted, 1=sorted, 2=foldcase/ -!_TAG_OUTPUT_EXCMD mixed /number, pattern, mixed, or combineV2/ -!_TAG_OUTPUT_FILESEP slash /slash or backslash/ -!_TAG_OUTPUT_MODE u-ctags /u-ctags or e-ctags/ -!_TAG_PATTERN_LENGTH_LIMIT 96 /0 for no limit/ -!_TAG_PROC_CWD /home/bg/src/bvi/bvi/ // -!_TAG_PROGRAM_AUTHOR Universal Ctags Team // -!_TAG_PROGRAM_NAME Universal Ctags /Derived from Exuberant Ctags/ -!_TAG_PROGRAM_URL https://ctags.io/ /official site/ -!_TAG_PROGRAM_VERSION 5.9.0 // -AND bvi.h /^#define AND /;" d -ANSI bmore.h /^# define ANSI$/;" d -ANSI bvi.h /^# define ANSI$/;" d -APPEND comm.c /^# define APPEND /;" d file: -ASCII bmore.h /^#define ASCII /;" d -ASCII bvi.h /^#define ASCII /;" d -ASCII_DEL bvi.h /^#define ASCII_DEL /;" d -A_ATTRIBUTES doscur.h /^#define A_ATTRIBUTES /;" d -A_BLINK doscur.h /^#define A_BLINK /;" d -A_BOLD doscur.h /^#define A_BOLD /;" d -A_CHARTEXT doscur.h /^#define A_CHARTEXT /;" d -A_NORMAL doscur.h /^#define A_NORMAL /;" d -A_REVERSE doscur.h /^#define A_REVERSE /;" d -A_STANDOUT doscur.h /^#define A_STANDOUT /;" d -AnzAdd bmore.c /^int AnzAdd;$/;" v typeref:typename:int -AnzAdd bvi.c /^int AnzAdd, Anzahl, Anzahl3;$/;" v typeref:typename:int -Anzahl bvi.c /^int AnzAdd, Anzahl, Anzahl3;$/;" v typeref:typename:int -Anzahl3 bvi.c /^int AnzAdd, Anzahl, Anzahl3;$/;" v typeref:typename:int -Ausgabe_Datei bvi.c /^FILE *Ausgabe_Datei;$/;" v typeref:typename:FILE * -BACKWARD bmore.h /^#define BACKWARD /;" d -BACKWARD bvi.h /^#define BACKWARD /;" d +!_TAG_PROGRAM_AUTHOR Darren Hiebert /dhiebert@users.sourceforge.net/ +!_TAG_PROGRAM_NAME Exuberant Ctags // +!_TAG_PROGRAM_URL http://ctags.sourceforge.net /official site/ +!_TAG_PROGRAM_VERSION 5.9~svn20110310 // +AND bvi.h 100;" d +ANSI bmore.h 108;" d +ANSI bvi.h 130;" d +APPEND comm.c 53;" d file: +APPEND comm.c 56;" d file: +ASCII bmore.h 87;" d +ASCII bvi.h 107;" d +ASCII_DEL bvi.h 116;" d +A_ATTRIBUTES doscur.h 56;" d +A_BLINK doscur.h 54;" d +A_BOLD doscur.h 52;" d +A_CHARTEXT doscur.h 55;" d +A_NORMAL doscur.h 50;" d +A_REVERSE doscur.h 53;" d +A_STANDOUT doscur.h 51;" d +AnzAdd bmore.c /^int AnzAdd;$/;" v +AnzAdd bvi.c /^int AnzAdd, Anzahl, Anzahl3;$/;" v +Anzahl bvi.c /^int AnzAdd, Anzahl, Anzahl3;$/;" v +Anzahl3 bvi.c /^int AnzAdd, Anzahl, Anzahl3;$/;" v +Ausgabe_Datei bvi.c /^FILE *Ausgabe_Datei;$/;" v +BACKWARD bmore.h 89;" d +BACKWARD bvi.h 109;" d BLOCK_BEGIN bvi.h /^ BLOCK_BEGIN = 1,$/;" e enum:_block_datum BLOCK_END bvi.h /^ BLOCK_END = 2,$/;" e enum:_block_datum BLOCK_LEN bvi.h /^ BLOCK_LEN = 4$/;" e enum:_block_datum -BLOCK_SPECIAL bmore.h /^#define BLOCK_SPECIAL /;" d -BLOCK_SPECIAL bvi.h /^#define BLOCK_SPECIAL /;" d -BS bmore.h /^#define BS /;" d -BS bvi.h /^#define BS /;" d -BUFFER bmore.h /^#define BUFFER /;" d -BUFFER bvi.h /^#define BUFFER /;" d -BVICTRL bmore.h /^#define BVICTRL(/;" d -BVICTRL bvi.h /^#define BVICTRL(/;" d -CHARACTER_SPECIAL bmore.h /^#define CHARACTER_SPECIAL /;" d -CHARACTER_SPECIAL bvi.h /^#define CHARACTER_SPECIAL /;" d -CMDLNG bvi.h /^#define CMDLNG(/;" d -CMDSZ comm.c /^#define CMDSZ /;" d file: -COLS dosio.c /^int COLS = 80;$/;" v typeref:typename:int -CR bmore.h /^#define CR /;" d -CR bvi.h /^#define CR /;" d -DELIM bmore.h /^# define DELIM /;" d -DELIM bvi.h /^# define DELIM /;" d -DIRECTORY bmore.h /^#define DIRECTORY /;" d -DIRECTORY bvi.h /^#define DIRECTORY /;" d -ECHO dosio.c /^int ECHO = TRUE;$/;" v typeref:typename:int -END bmore.h /^#define END /;" d -END bvi.h /^#define END /;" d -ERR doscur.h /^#define ERR /;" d -ERROR bmore.h /^#define ERROR /;" d -ERROR bvi.h /^#define ERROR /;" d -ESC bmore.h /^#define ESC /;" d -ESC bvi.h /^#define ESC /;" d -ESC doscur.h /^#define ESC /;" d -FALSE bmore.h /^# define FALSE /;" d -FALSE bvi.h /^# define FALSE /;" d -FALSE doscur.h /^#define FALSE /;" d -FORWARD bmore.h /^#define FORWARD /;" d -FORWARD bvi.h /^#define FORWARD /;" d -HAVE_FCNTL_H dosconf.h /^#define HAVE_FCNTL_H /;" d -HAVE_LOCALE_H dosconf.h /^# define HAVE_LOCALE_H /;" d -HAVE_MEMMOVE dosconf.h /^#define HAVE_MEMMOVE /;" d -HAVE_STRDUP dosconf.h /^#define HAVE_STRDUP /;" d -HAVE_STRTOL dosconf.h /^#define HAVE_STRTOL /;" d -HELPFILE bmore.c /^# define HELPFILE /;" d file: -HEX bvi.h /^#define HEX /;" d -Home bm_unix.c /^char *Home; \/* go to home *\/$/;" v typeref:typename:char * -JOEHTG bvi.h /^#define JOEHTG$/;" d -KEY_BACKSPACE doscur.h /^#define KEY_BACKSPACE /;" d -KEY_DC doscur.h /^#define KEY_DC /;" d -KEY_DOWN doscur.h /^#define KEY_DOWN /;" d -KEY_ENTER doscur.h /^#define KEY_ENTER /;" d -KEY_F doscur.h /^#define KEY_F(/;" d -KEY_F0 doscur.h /^#define KEY_F0 /;" d -KEY_HOME doscur.h /^#define KEY_HOME /;" d -KEY_IC doscur.h /^#define KEY_IC /;" d -KEY_LEFT doscur.h /^#define KEY_LEFT /;" d -KEY_LL doscur.h /^#define KEY_LL /;" d -KEY_NPAGE doscur.h /^#define KEY_NPAGE /;" d -KEY_PPAGE doscur.h /^#define KEY_PPAGE /;" d -KEY_RETURN doscur.h /^#define KEY_RETURN /;" d -KEY_RIGHT doscur.h /^#define KEY_RIGHT /;" d -KEY_UP doscur.h /^#define KEY_UP /;" d -LINES dosio.c /^int LINES = 25;$/;" v typeref:typename:int -LROTATE bvi.h /^#define LROTATE /;" d -LSHIFT bvi.h /^#define LSHIFT /;" d -MAXCMD bmore.h /^#define MAXCMD /;" d -MAXCMD bvi.h /^#define MAXCMD /;" d -MAXNAME comm.c /^#define MAXNAME /;" d file: -MAX_ONE_ARG comm.c /^#define MAX_ONE_ARG /;" d file: -MAX_ONE_FILE comm.c /^#define MAX_ONE_FILE /;" d file: -NEG bvi.h /^#define NEG /;" d -NEW bmore.h /^#define NEW /;" d -NEW bvi.h /^#define NEW /;" d -NL bmore.h /^#define NL /;" d -NL bvi.h /^#define NL /;" d -NODEL dosio.c /^int NODEL = FALSE;$/;" v typeref:typename:int -NOT bvi.h /^#define NOT /;" d -NO_ADDR comm.c /^#define NO_ADDR /;" d file: -NO_ARG comm.c /^#define NO_ARG /;" d file: -NULL bmore.h /^# define NULL /;" d -NULL bvi.h /^# define NULL /;" d -OFF_T_MAX io.c /^# define OFF_T_MAX /;" d file: -ONE bmore.h /^#define ONE /;" d -ONE bvi.h /^#define ONE /;" d -ONE_ARG comm.c /^#define ONE_ARG /;" d file: -ONE_FILE comm.c /^#define ONE_FILE /;" d file: -OR bvi.h /^#define OR /;" d -P set.h /^#define P(/;" d -PARTIAL bmore.h /^#define PARTIAL /;" d -PARTIAL bvi.h /^#define PARTIAL /;" d -PRINTF bmore.c /^# define PRINTF /;" d file: -PTR bmore.h /^# define PTR /;" d -PTR bvi.h /^# define PTR /;" d -P_AW set.h /^#define P_AW /;" d -P_BOOL set.h /^#define P_BOOL /;" d -P_CHANGED set.h /^#define P_CHANGED /;" d -P_CM set.h /^#define P_CM /;" d -P_CO set.h /^#define P_CO /;" d -P_EB set.h /^#define P_EB /;" d -P_HL set.h /^#define P_HL /;" d -P_IC set.h /^#define P_IC /;" d -P_LI set.h /^#define P_LI /;" d -P_MA set.h /^#define P_MA /;" d -P_MM set.h /^#define P_MM /;" d -P_MO set.h /^#define P_MO /;" d -P_NUM set.h /^#define P_NUM /;" d -P_OF set.h /^#define P_OF /;" d -P_RE set.h /^#define P_RE /;" d -P_RO set.h /^#define P_RO /;" d -P_SS set.h /^#define P_SS /;" d -P_TE set.h /^#define P_TE /;" d -P_TEXT set.h /^#define P_TEXT /;" d -P_TT set.h /^#define P_TT /;" d -P_US set.h /^#define P_US /;" d -P_WL set.h /^#define P_WL /;" d -P_WS set.h /^#define P_WS /;" d -REGULAR bmore.h /^#define REGULAR /;" d -REGULAR bvi.h /^#define REGULAR /;" d -REPLACE bmore.h /^#define REPLACE /;" d -RROTATE bvi.h /^#define RROTATE /;" d -RSHIFT bvi.h /^#define RSHIFT /;" d -SEARCH bmore.h /^#define SEARCH /;" d -SEARCH bvi.h /^#define SEARCH /;" d -SKIP_WHITE bvi.h /^#define SKIP_WHITE /;" d -STAR bmore.h /^#define STAR /;" d -STAR bvi.h /^#define STAR /;" d -STDC_HEADERS dosconf.h /^#define STDC_HEADERS /;" d -S_GLOBAL bvi.h /^#define S_GLOBAL /;" d -S_ISBLK bvi.h /^#define S_ISBLK(/;" d -S_ISCHR bvi.h /^#define S_ISCHR(/;" d -S_ISDIR bvi.h /^#define S_ISDIR(/;" d -S_ISFIFO bvi.h /^#define S_ISFIFO(/;" d -S_ISREG bvi.h /^#define S_ISREG(/;" d -TBUFSIZ bm_dos.c /^#define TBUFSIZ /;" d file: -TBUFSIZ bm_unix.c /^#define TBUFSIZ /;" d file: -TRUE bmore.h /^# define TRUE /;" d -TRUE bvi.h /^# define TRUE /;" d -TRUE doscur.h /^#define TRUE /;" d -U_APPEND bvi.h /^#define U_APPEND /;" d -U_BACK bvi.h /^#define U_BACK /;" d -U_DELETE bvi.h /^#define U_DELETE /;" d -U_EDIT bvi.h /^#define U_EDIT /;" d -U_INSERT bvi.h /^#define U_INSERT /;" d -U_TILDE bvi.h /^#define U_TILDE /;" d -U_TRUNC bvi.h /^#define U_TRUNC /;" d -VERSION patchlevel.h /^#define VERSION /;" d -WINDOW doscur.h /^#define WINDOW /;" d -WRITE comm.c /^# define WRITE /;" d file: -XOR bvi.h /^#define XOR /;" d +BLOCK_SPECIAL bmore.h 79;" d +BLOCK_SPECIAL bvi.h 76;" d +BS bmore.h 92;" d +BS bvi.h 112;" d +BUFFER bmore.h 120;" d +BUFFER bvi.h 144;" d +BVICTRL bmore.h 96;" d +BVICTRL bvi.h 115;" d +CHARACTER_SPECIAL bmore.h 78;" d +CHARACTER_SPECIAL bvi.h 75;" d +CMDLNG bvi.h 118;" d +CMDSZ comm.c 59;" d file: +COLS dosio.c /^int COLS = 80;$/;" v +CR bmore.h 90;" d +CR bvi.h 110;" d +DELIM bmore.h 111;" d +DELIM bmore.h 116;" d +DELIM bvi.h 133;" d +DELIM bvi.h 140;" d +DIRECTORY bmore.h 77;" d +DIRECTORY bvi.h 74;" d +ECHO dosio.c /^int ECHO = TRUE;$/;" v +END bmore.h 83;" d +END bvi.h 80;" d +ERR doscur.h 147;" d +ERROR bmore.h 74;" d +ERROR bvi.h 71;" d +ESC bmore.h 93;" d +ESC bvi.h 113;" d +ESC doscur.h 31;" d +FALSE bmore.h 104;" d +FALSE bvi.h 126;" d +FALSE doscur.h 29;" d +FORWARD bmore.h 88;" d +FORWARD bvi.h 108;" d +HAVE_CURSES_H acconfig.h 5;" d +HAVE_FCNTL_H dosconf.h 40;" d +HAVE_LOCALE_H dosconf.h 44;" d +HAVE_MEMMOVE dosconf.h 31;" d +HAVE_NCURSESW_CURSES_H acconfig.h 7;" d +HAVE_NCURSES_H acconfig.h 3;" d +HAVE_NCURSES_TERM_H acconfig.h 13;" d +HAVE_STRDUP dosconf.h 34;" d +HAVE_STRTOL dosconf.h 37;" d +HELPFILE bmore.c 45;" d file: +HELPFILE bmore.c 47;" d file: +HEX bvi.h 106;" d +Home bm_unix.c /^char *Home; \/* go to home *\/$/;" v +JOEHTG bvi.h 45;" d +KEY_BACKSPACE doscur.h 42;" d +KEY_DC doscur.h 45;" d +KEY_DOWN doscur.h 34;" d +KEY_ENTER doscur.h 41;" d +KEY_F doscur.h 33;" d +KEY_F0 doscur.h 32;" d +KEY_HOME doscur.h 43;" d +KEY_IC doscur.h 46;" d +KEY_LEFT doscur.h 36;" d +KEY_LL doscur.h 44;" d +KEY_NPAGE doscur.h 38;" d +KEY_PPAGE doscur.h 39;" d +KEY_RETURN doscur.h 40;" d +KEY_RIGHT doscur.h 37;" d +KEY_UP doscur.h 35;" d +LINES dosio.c /^int LINES = 25;$/;" v +LROTATE bvi.h 98;" d +LSHIFT bvi.h 96;" d +MAXCMD bmore.h 119;" d +MAXCMD bvi.h 143;" d +MAXNAME comm.c 60;" d file: +MAX_ONE_ARG comm.c 65;" d file: +MAX_ONE_FILE comm.c 67;" d file: +NEED_PUTC_CHAR acconfig.h 11;" d +NEED_PUTC_CHAR bm_unix.c 54;" d file: +NEG bvi.h 103;" d +NEW bmore.h 76;" d +NEW bvi.h 73;" d +NL bmore.h 91;" d +NL bvi.h 111;" d +NODEL dosio.c /^int NODEL = FALSE;$/;" v +NOT bvi.h 104;" d +NO_ADDR comm.c 62;" d file: +NO_ARG comm.c 63;" d file: +NO_SYSERRL acconfig.h 9;" d +NULL bmore.h 99;" d +NULL bvi.h 121;" d +OFF_T_MAX io.c 49;" d file: +ONE bmore.h 84;" d +ONE bvi.h 81;" d +ONE_ARG comm.c 64;" d file: +ONE_FILE comm.c 66;" d file: +OR bvi.h 101;" d +P set.h 78;" d +PARTIAL bmore.h 80;" d +PARTIAL bvi.h 77;" d +PRINTF bmore.c 40;" d file: +PRINTF bmore.c 42;" d file: +PTR bmore.h 109;" d +PTR bmore.h 115;" d +PTR bvi.h 131;" d +PTR bvi.h 139;" d +P_AW set.h 55;" d +P_BOOL set.h 43;" d +P_CHANGED set.h 46;" d +P_CM set.h 56;" d +P_CO set.h 73;" d +P_EB set.h 57;" d +P_HL set.h 71;" d +P_IC set.h 58;" d +P_LI set.h 68;" d +P_MA set.h 59;" d +P_MM set.h 60;" d +P_MO set.h 64;" d +P_NUM set.h 44;" d +P_OF set.h 61;" d +P_RE set.h 72;" d +P_RO set.h 62;" d +P_SS set.h 63;" d +P_TE set.h 66;" d +P_TEXT set.h 45;" d +P_TT set.h 65;" d +P_US set.h 67;" d +P_WL set.h 69;" d +P_WS set.h 70;" d +REGULAR bmore.h 75;" d +REGULAR bvi.h 72;" d +REPLACE bmore.h 95;" d +RROTATE bvi.h 99;" d +RSHIFT bvi.h 97;" d +SEARCH bmore.h 94;" d +SEARCH bvi.h 114;" d +SKIP_WHITE bvi.h 146;" d +STAR bmore.h 85;" d +STAR bvi.h 82;" d +STDC_HEADERS dosconf.h 28;" d +S_GLOBAL bvi.h 93;" d +S_ISBLK bvi.h 210;" d +S_ISCHR bvi.h 209;" d +S_ISDIR bvi.h 208;" d +S_ISFIFO bvi.h 212;" d +S_ISREG bvi.h 211;" d +TBUFSIZ bm_dos.c 32;" d file: +TBUFSIZ bm_unix.c 34;" d file: +TRUE bmore.h 103;" d +TRUE bvi.h 125;" d +TRUE doscur.h 28;" d +U_APPEND bvi.h 90;" d +U_BACK bvi.h 89;" d +U_DELETE bvi.h 88;" d +U_EDIT bvi.h 85;" d +U_INSERT bvi.h 87;" d +U_TILDE bvi.h 91;" d +U_TRUNC bvi.h 86;" d +VERSION patchlevel.h 1;" d +WINDOW doscur.h 60;" d +WRITE comm.c 52;" d file: +WRITE comm.c 55;" d file: +XOR bvi.h 102;" d _block_datum bvi.h /^typedef enum _block_datum {$/;" g -act_pat re.c /^char act_pat[MAXCMD]; \/* found pattern *\/$/;" v typeref:typename:char[] -addch doscur.h /^#define addch(/;" d -addfile io.c /^addfile(fname)$/;" f -addr_flag comm.c /^int addr_flag;$/;" v typeref:typename:int -addr_form bmore.c /^char addr_form[15];$/;" v typeref:typename:char[15] -addr_form bvi.c /^char addr_form[15];$/;" v typeref:typename:char[15] -addstr doscur.h /^#define addstr(/;" d -again recomp.c /^int again = 0;$/;" v typeref:typename:int -alloc_buf io.c /^alloc_buf(n, buffer)$/;" f -altfile comm.c /^static char *altfile = NULL; \/* alternate file *\/$/;" v typeref:typename:char * file: -ambigous comm.c /^char *ambigous = "Ambigous|Too many file names";$/;" v typeref:typename:char * -ambvalue comm.c /^char *ambvalue = "Ambigous|Too many values";$/;" v typeref:typename:char * -arrnum bmore.c /^int arrnum = 0;$/;" v typeref:typename:int -arrnum bvi.c /^int arrnum = 0;$/;" v typeref:typename:int -ascii_comp recomp.c /^ascii_comp(smem, pattern)$/;" f -ascii_flag bmore.c /^int ascii_flag = 0;$/;" v typeref:typename:int -attrset dosio.c /^attrset(int attr)$/;" f typeref:typename:void -backsearch re.c /^backsearch(start, mode)$/;" f -beep doscur.h /^#define beep(/;" d -block_begin bvi.c /^off_t block_begin, block_end, block_size;$/;" v typeref:typename:off_t +act_pat re.c /^char act_pat[MAXCMD]; \/* found pattern *\/$/;" v +addch doscur.h 95;" d +addfile dosio.c /^addfile(char *fname)$/;" f +addfile io.c /^addfile(char *fname)$/;" f +addr_flag comm.c /^int addr_flag;$/;" v +addr_form bmore.c /^char addr_form[15];$/;" v +addr_form bvi.c /^char addr_form[15];$/;" v +addstr doscur.h 99;" d +again recomp.c /^int again = 0;$/;" v +alloc_buf dosio.c /^alloc_buf(off_t n, char **buffer)$/;" f +alloc_buf io.c /^alloc_buf(off_t n, char **buffer)$/;" f +altfile comm.c /^static char *altfile = NULL; \/* alternate file *\/$/;" v file: +ambigous comm.c /^char *ambigous = "Ambiguous|Too many file names";$/;" v +ambvalue comm.c /^char *ambvalue = "Ambiguous|Too many values";$/;" v +arrnum bmore.c /^int arrnum = 0;$/;" v +arrnum bvi.c /^int arrnum = 0;$/;" v +ascii_comp recomp.c /^ascii_comp(char *smem, char *pattern)$/;" f +ascii_flag bmore.c /^int ascii_flag = 0;$/;" v +attrset dosio.c /^attrset(int attr)$/;" f +backsearch re.c /^backsearch(PTR start, char mode)$/;" f +beep doscur.h 76;" d +block_begin bvi.c /^off_t block_begin, block_end, block_size;$/;" v block_datum bvi.h /^} block_datum;$/;" t typeref:enum:_block_datum -block_end bvi.c /^off_t block_begin, block_end, block_size;$/;" v typeref:typename:off_t -block_flag bvi.c /^int block_flag = 0;$/;" v typeref:typename:int -block_read io.c /^static off_t block_read;$/;" v typeref:typename:off_t file: -block_size bvi.c /^off_t block_begin, block_end, block_size;$/;" v typeref:typename:off_t -bmbeep bmore.c /^bmbeep() {$/;" f typeref:typename:void -bmore_search_pat bmore.c /^char bmore_search_pat[BUFFER]; \/* \/ or ? command *\/$/;" v typeref:typename:char[] -bmregexec bmore.c /^bmregexec(scan)$/;" f -bmsearch bmore.c /^bmsearch(ch)$/;" f -bregexec re.c /^bregexec(start, scan)$/;" f +block_end bvi.c /^off_t block_begin, block_end, block_size;$/;" v +block_flag bvi.c /^int block_flag = 0;$/;" v +block_read io.c /^static off_t block_read;$/;" v file: +block_size bvi.c /^off_t block_begin, block_end, block_size;$/;" v +bmbeep bmore.c /^bmbeep() {$/;" f +bmore_search_pat bmore.c /^char bmore_search_pat[BUFFER]; \/* \/ or ? command *\/$/;" v +bmregexec bmore.c /^bmregexec(char *scan)$/;" f +bmsearch bmore.c /^bmsearch(int ch)$/;" f +bregexec re.c /^bregexec(PTR start, char *scan)$/;" f buf comm.c /^static struct stat buf;$/;" v typeref:struct:stat file: buf dosio.c /^static struct stat buf;$/;" v typeref:struct:stat file: buf io.c /^static struct stat buf;$/;" v typeref:struct:stat file: -buf set.c /^static char buf[MAXCMD+1];$/;" v typeref:typename:char[] file: -buffer1 bmore.c /^char buffer1[MAXCMD], buffer2[MAXCMD];$/;" v typeref:typename:char[] -buffer2 bmore.c /^char buffer1[MAXCMD], buffer2[MAXCMD];$/;" v typeref:typename:char[] -bvi_init io.c /^bvi_init(dir)$/;" f -bytepos bmore.c /^off_t bytepos, oldpos;$/;" v typeref:typename:off_t -c_argc comm.c /^static int c_argc = 0;$/;" v typeref:typename:int file: -c_argv comm.c /^static char *c_argv[9];$/;" v typeref:typename:char * [9] file: -c_flag bmore.c /^int c_flag = 0, d_flag = 0, r_flag = 0;$/;" v typeref:typename:int -calc_addr re.c /^calc_addr(pointer, def_addr)$/;" f -calc_size bvi.c /^calc_size(arg)$/;" f -cbreak doscur.h /^#define cbreak(/;" d -chk_comm comm.c /^chk_comm(flag)$/;" f -chtype doscur.h /^#define chtype /;" d -clear doscur.h /^#define clear(/;" d -clear_marks edit.c /^clear_marks()$/;" f typeref:typename:void -clear_sc bm_unix.c /^char *clear_sc; \/* clear screen *\/$/;" v typeref:typename:char * -clearscreen bm_dos.c /^clearscreen()$/;" f typeref:typename:void -clearscreen bm_unix.c /^clearscreen()$/;" f typeref:typename:void -clearstr comm.c /^clearstr()$/;" f typeref:typename:void +buf set.c /^static char buf[MAXCMD+1];$/;" v file: +buffer1 bmore.c /^char buffer1[MAXCMD], buffer2[MAXCMD];$/;" v +buffer2 bmore.c /^char buffer1[MAXCMD], buffer2[MAXCMD];$/;" v +bvi_init dosio.c /^bvi_init(char *dir)$/;" f +bvi_init io.c /^bvi_init(char *dir)$/;" f +bytepos bmore.c /^off_t bytepos, oldpos;$/;" v +c_argc comm.c /^static int c_argc = 0;$/;" v file: +c_argv comm.c /^static char *c_argv[9];$/;" v file: +c_flag bmore.c /^int c_flag = 0, d_flag = 0, r_flag = 0;$/;" v +calc_addr re.c /^calc_addr(char **pointer, PTR def_addr)$/;" f +calc_size bvi.c /^calc_size(char *arg)$/;" f +cbreak doscur.h 136;" d +chk_comm comm.c /^chk_comm(int flag)$/;" f +chtype doscur.h 58;" d +clear doscur.h 83;" d +clear_marks edit.c /^clear_marks()$/;" f +clear_sc bm_unix.c /^char *clear_sc; \/* clear screen *\/$/;" v +clearscreen bm_dos.c /^clearscreen()$/;" f +clearscreen bm_unix.c /^clearscreen()$/;" f +clearstr comm.c /^clearstr()$/;" f cleartoeol bm_dos.c /^cleartoeol()$/;" f -cleartoeol bm_unix.c /^cleartoeol()$/;" f typeref:typename:void -clrtoeol doscur.h /^#define clrtoeol(/;" d -cmdbuf bmore.c /^static char cmdbuf[2 * MAXCMD];$/;" v typeref:typename:char[] file: -cmdstr bvi.c /^char cmdstr[MAXCMD+1] = "";$/;" v typeref:typename:char[] -cnt bmore.c /^static int cnt = 0;$/;" v typeref:typename:int file: -contrd edit.c /^char contrd[][4] = {"NUL", " ^A", " ^B", " ^C", " ^D", " ^E", " ^F", "BEL",$/;" v typeref:typename:char[][4] -contru edit.c /^char contru[][4] = {"NUL", "SOH", "STX", "ETX", "EOT", "ENQ", "ACK", "BEL",$/;" v typeref:typename:char[][4] -copyright bmore.c /^char *copyright = "GPL (C) 1990-2022 by Gerhard Buergmann";$/;" v typeref:typename:char * -copyright bvi.c /^char *copyright = "(C) GPL 1996-2023 by Gerhard Buergmann";$/;" v typeref:typename:char * -corr bmore.c /^int corr = 0, do_header = 0, to_print;$/;" v typeref:typename:int -cur_back edit.c /^cur_back()$/;" f typeref:typename:int -cur_forw edit.c /^cur_forw(check)$/;" f -curfile bvi.c /^int curfile; \/* number of the current file *\/$/;" v typeref:typename:int -curpos bvi.c /^PTR curpos;$/;" v typeref:typename:PTR -curr_file bmore.c /^FILE *curr_file = NULL, *help_file;$/;" v typeref:typename:FILE * -current bvi.c /^PTR current;$/;" v typeref:typename:PTR -current_start bvi.c /^PTR current_start;$/;" v typeref:typename:PTR -d_flag bmore.c /^int c_flag = 0, d_flag = 0, r_flag = 0;$/;" v typeref:typename:int -dbug bm_dos.c /^FILE *dbug;$/;" v typeref:typename:FILE * -delch dosio.c /^delch()$/;" f typeref:typename:void -deleteln doscur.h /^#define deleteln(/;" d -dlines bm_unix.c /^int dum_opt, dlines;$/;" v typeref:typename:int -do_append bvi.c /^do_append(count, buf)$/;" f -do_back edit.c /^do_back(n, start)$/;" f -do_delete edit.c /^do_delete(n, start)$/;" f -do_exit comm.c /^do_exit()$/;" f typeref:typename:void -do_ft edit.c /^do_ft(ch, flag)$/;" f -do_header bmore.c /^int corr = 0, do_header = 0, to_print;$/;" v typeref:typename:int -do_ins_chg edit.c /^do_ins_chg(start, arg, mode)$/;" f -do_logic set.c /^do_logic(mode, str)$/;" f -do_mark edit.c /^do_mark(mark, addr)$/;" f -do_next bmore.c /^do_next(n)$/;" f -do_over bvi.c /^do_over(loc, n, buf)$/;" f -do_put bvi.c /^do_put(loc, n, buf)$/;" f -do_shell io.c /^do_shell()$/;" f typeref:typename:void -do_substitution re.c /^do_substitution(delim, line, startpos, endpos)$/;" f -do_tilde bvi.c /^do_tilde(count)$/;" f -do_undo bvi.c /^do_undo()$/;" f typeref:typename:void -do_z edit.c /^do_z(mode)$/;" f -docmdline comm.c /^docmdline(cmdline)$/;" f -doecmd comm.c /^doecmd(arg, force)$/;" f -doset set.c /^doset(arg)$/;" f +cleartoeol bm_unix.c /^cleartoeol()$/;" f +clrtoeol doscur.h 79;" d +cmdbuf bmore.c /^static char cmdbuf[2 * MAXCMD];$/;" v file: +cmdstr bvi.c /^char cmdstr[MAXCMD+1] = "";$/;" v +cnt bmore.c /^static int cnt = 0;$/;" v file: +contrd edit.c /^char contrd[][4] = {"NUL", " ^A", " ^B", " ^C", " ^D", " ^E", " ^F", "BEL",$/;" v +contru edit.c /^char contru[][4] = {"NUL", "SOH", "STX", "ETX", "EOT", "ENQ", "ACK", "BEL",$/;" v +copyright bmore.c /^char *copyright = "GPL (C) 1990-2022 by Gerhard Buergmann";$/;" v +copyright bvi.c /^char *copyright = "(C) GPL 1996-2025 by Gerhard Buergmann";$/;" v +corr bmore.c /^int corr = 0, do_header = 0, to_print;$/;" v +cur_back edit.c /^cur_back()$/;" f +cur_forw edit.c /^cur_forw(int check)$/;" f +curfile bvi.c /^int curfile; \/* number of the current file *\/$/;" v +curpos bvi.c /^PTR curpos;$/;" v +curr_file bmore.c /^FILE *curr_file = NULL, *help_file;$/;" v +current bvi.c /^PTR current;$/;" v +current_start bvi.c /^PTR current_start;$/;" v +d_flag bmore.c /^int c_flag = 0, d_flag = 0, r_flag = 0;$/;" v +d_memcpy dosio.c /^d_memcpy(PTR dest, PTR src, off_t n)$/;" f +d_memmove dosio.c /^d_memmove(PTR dest, PTR src, off_t n)$/;" f +dbug bm_dos.c /^FILE *dbug;$/;" v +delch dosio.c /^delch()$/;" f +deleteln doscur.h 110;" d +dlines bm_unix.c /^int dum_opt, dlines;$/;" v +do_append bvi.c /^do_append(off_t count, char *buf)$/;" f +do_back edit.c /^do_back(off_t n, PTR start)$/;" f +do_delete edit.c /^do_delete(off_t n, PTR start)$/;" f +do_exit comm.c /^do_exit()$/;" f +do_ft edit.c /^do_ft(int ch, int flag)$/;" f +do_header bmore.c /^int corr = 0, do_header = 0, to_print;$/;" v +do_ins_chg edit.c /^do_ins_chg(PTR start, char *arg, int mode)$/;" f +do_logic set.c /^do_logic(int mode, char *str)$/;" f +do_mark edit.c /^do_mark(int mark, PTR addr)$/;" f +do_next bmore.c /^do_next(int n)$/;" f +do_over bvi.c /^do_over(PTR loc, off_t n, PTR buf)$/;" f +do_put bvi.c /^do_put(PTR loc, off_t n, PTR buf)$/;" f +do_shell dosio.c /^do_shell()$/;" f +do_shell io.c /^do_shell()$/;" f +do_substitution re.c /^do_substitution(int delim, char *line, PTR startpos, PTR endpos)$/;" f +do_tilde bvi.c /^do_tilde(off_t count)$/;" f +do_undo bvi.c /^do_undo()$/;" f +do_z edit.c /^do_z(int mode)$/;" f +docmdline comm.c /^docmdline(char *cmdline)$/;" f +doecmd comm.c /^doecmd(char *arg, int force)$/;" f +doset set.c /^doset(char *arg)$/;" f doshell bm_dos.c /^doshell(cmd)$/;" f -doshell bm_unix.c /^doshell(cmd)$/;" f -doupdate doscur.h /^#define doupdate(/;" d -dum_opt bm_unix.c /^int dum_opt, dlines;$/;" v typeref:typename:int -dup_print_flag bmore.c /^int dup_print_flag = 0;$/;" v typeref:typename:int -echo doscur.h /^#define echo(/;" d -edit edit.c /^edit(mode)$/;" f -edits bvi.c /^int edits = 0;$/;" v typeref:typename:int -emptyclass bmore.c /^char *emptyclass = "Empty byte class '[]' or '[^]'";$/;" v typeref:typename:char * -emptyclass re.c /^char *emptyclass = "Bad character class|Empty byte class '[]' or '[^]' cannot match";$/;" v typeref:typename:char * -emsg bmore.c /^emsg(s)$/;" f -emsg comm.c /^emsg(s)$/;" f -end_addr comm.c /^PTR end_addr;$/;" v typeref:typename:PTR -end_word re.c /^end_word(start)$/;" f -endwin doscur.h /^#define endwin(/;" d -enlarge io.c /^enlarge(add)$/;" f -env bvi.c /^jmp_buf env; \/* context for `longjmp' function *\/$/;" v typeref:typename:jmp_buf -erase doscur.h /^#define erase(/;" d -erase_ln bm_unix.c /^char *erase_ln; \/* erase line *\/$/;" v typeref:typename:char * -erasechar doscur.h /^#define erasechar(/;" d -estring bmore.c /^char estring[MAXCMD] = ""; \/* string for shell escape *\/$/;" v typeref:typename:char[] -extra comm.c /^char *extra = "Extra chars|Extra characters at end of command";$/;" v typeref:typename:char * -exval bmore.c /^int exval = 0;$/;" v typeref:typename:int -fbuf set.c /^static char fbuf[MAXCMD+1];$/;" v typeref:typename:char[] file: -ffp set.c /^static FILE *ffp;$/;" v typeref:typename:FILE * file: -file_nr bmore.c /^int file_nr = 0; \/* number of current input file *\/$/;" v typeref:typename:int -fileinfo edit.c /^fileinfo(fname)$/;" f -filemode dosio.c /^int filemode;$/;" v typeref:typename:int -filemode io.c /^int filemode;$/;" v typeref:typename:int -files bmore.c /^char **files; \/* list of input files *\/$/;" v typeref:typename:char ** -files bvi.c /^char **files; \/* list of input files *\/$/;" v typeref:typename:char ** -filesize bmore.c /^off_t screen_home, filesize;$/;" v typeref:typename:off_t -filesize bvi.c /^off_t filesize, memsize, undosize;$/;" v typeref:typename:off_t -flags set.h /^ int flags;$/;" m struct:param typeref:typename:int -flash doscur.h /^#define flash(/;" d -flushinp doscur.h /^#define flushinp(/;" d -fname_buf bvi.c /^char *fname_buf = NULL;$/;" v typeref:typename:char * -fnum bm_unix.c /^int fnum, no_intty, no_tty, slow_tty;$/;" v typeref:typename:int -from_file set.c /^static int from_file = 0;$/;" v typeref:typename:int file: -fsearch re.c /^fsearch(start, end, smem)$/;" f -fsearch_end re.c /^fsearch_end(start, end, smem, s_end)$/;" f -fullname set.h /^ char *fullname; \/* full parameter name *\/$/;" m struct:param typeref:typename:char * -getbegyx doscur.h /^#define getbegyx(/;" d -getcbuff edit.c /^static char getcbuff[BUFFER];$/;" v typeref:typename:char[] file: -getch dosio.c /^getch()$/;" f typeref:typename:int -getcmdstr set.c /^getcmdstr(p, x)$/;" f -getcnext edit.c /^static char *getcnext = NULL;$/;" v typeref:typename:char * file: -getmaxyx doscur.h /^#define getmaxyx(/;" d -getyx doscur.h /^#define getyx(/;" d -got_int bm_dos.c /^int got_int;$/;" v typeref:typename:int -got_int bm_unix.c /^int got_int;$/;" v typeref:typename:int -help_file bmore.c /^FILE *curr_file = NULL, *help_file;$/;" v typeref:typename:FILE * -helppath bmore.c /^char helppath[MAXCMD];$/;" v typeref:typename:char[] -hex_comp recomp.c /^hex_comp(smem, pattern)$/;" f -hexchar recomp.c /^hexchar()$/;" f typeref:typename:int -highlight bm_dos.c /^highlight()$/;" f typeref:typename:void -highlight bm_unix.c /^highlight()$/;" f typeref:typename:void -hl_spat edit.c /^long hl_spat = 0;$/;" v typeref:typename:long -home bm_dos.c /^home()$/;" f typeref:typename:void -home bm_unix.c /^home()$/;" f typeref:typename:void -icnt bmore.c /^static int icnt = 0;$/;" v typeref:typename:int file: -idlok doscur.h /^#define idlok(/;" d -ignore_case recomp.c /^int ignore_case = 0;$/;" v typeref:typename:int -inch dosio.c /^inch()$/;" f typeref:typename:int -init_byte bmore.c /^off_t init_byte = 0;$/;" v typeref:typename:off_t -init_search bmore.c /^int init_search = 0;$/;" v typeref:typename:int -initscr doscur.h /^#define initscr(/;" d -initterm bm_dos.c /^initterm()$/;" f typeref:typename:void -initterm bm_unix.c /^initterm()$/;" f typeref:typename:void -insch dosio.c /^insch(int c)$/;" f typeref:typename:void -insertln doscur.h /^#define insertln(/;" d -jmpproc bvi.c /^jmpproc(sig)$/;" f -keypad doscur.h /^#define keypad(/;" d -last_motion bvi.c /^PTR last_motion;$/;" v typeref:typename:PTR -last_search bmore.c /^off_t last_search = 0;$/;" v typeref:typename:off_t -linbuf edit.c /^char linbuf[16384];$/;" v typeref:typename:char[16384] -line bvi.c /^static char line[MAXCMD+1];$/;" v typeref:typename:char[] file: -lineout edit.c /^lineout()$/;" f typeref:typename:int -load dosio.c /^load(char *fname)$/;" f typeref:typename:off_t -load io.c /^load(fname)$/;" f -loc bvi.c /^int loc;$/;" v typeref:typename:int -magic recomp.c /^int magic = 1;$/;" v typeref:typename:int -main bmore.c /^main(argc, argv)$/;" f -main bvi.c /^main(argc, argv)$/;" f -mark bvi.c /^static int mark;$/;" v typeref:typename:int file: -markbuf bvi.c /^PTR markbuf[26];$/;" v typeref:typename:PTR[26] -maxpos bvi.c /^PTR maxpos;$/;" v typeref:typename:PTR -maxx bmore.c /^int maxx, maxy;$/;" v typeref:typename:int -maxx bvi.c /^int maxx, maxy, x, xx, y;$/;" v typeref:typename:int -maxy bmore.c /^int maxx, maxy;$/;" v typeref:typename:int -maxy bvi.c /^int maxx, maxy, x, xx, y;$/;" v typeref:typename:int -mem bvi.c /^PTR mem = NULL;$/;" v typeref:typename:PTR -memcpy bvi.h /^# define memcpy /;" d -memmove bm_unix.c /^memmove(s1, s2, n)$/;" f -memmove bvi.h /^# define memmove /;" d -memmove io.c /^memmove(s1, s2, n)$/;" f -memsize bvi.c /^off_t filesize, memsize, undosize;$/;" v typeref:typename:off_t -morefiles comm.c /^char *morefiles = "more files@to edit";$/;" v typeref:typename:char * -move doscur.h /^#define move(/;" d -movebyte edit.c /^movebyte()$/;" f typeref:typename:void -msg comm.c /^msg(s)$/;" f -mvaddch doscur.h /^#define mvaddch(/;" d -mvaddstr doscur.h /^#define mvaddstr(/;" d -mvgetch doscur.h /^#define mvgetch(/;" d -mvgetstr doscur.h /^#define mvgetstr(/;" d -mvinch dosio.c /^mvinch(int y, int x)$/;" f typeref:typename:int -mvinsch doscur.h /^#define mvinsch(/;" d -mvprintw doscur.h /^#define mvprintw(/;" d -mvscanw doscur.h /^#define mvscanw(/;" d -mvwaddch doscur.h /^#define mvwaddch(/;" d -mvwaddstr doscur.h /^#define mvwaddstr(/;" d -mvwgetch doscur.h /^#define mvwgetch(/;" d -mvwgetstr doscur.h /^#define mvwgetstr(/;" d -mvwprintw doscur.h /^#define mvwprintw(/;" d -mvwscanw doscur.h /^#define mvwscanw(/;" d -mymaxx bmore.c /^int mymaxx = 0, mymaxy = 0;$/;" v typeref:typename:int -mymaxy bmore.c /^int mymaxx = 0, mymaxy = 0;$/;" v typeref:typename:int -name bmore.c /^char *name = NULL;$/;" v typeref:typename:char * -name bvi.c /^char *name = NULL;$/;" v typeref:typename:char * -new_screen edit.c /^new_screen()$/;" f typeref:typename:void -newwin doscur.h /^#define newwin(/;" d -nextchar bmore.c /^nextchar()$/;" f typeref:typename:int -nl doscur.h /^#define nl(/;" d -no_intty bm_dos.c /^int no_intty, no_tty;$/;" v typeref:typename:int -no_intty bm_unix.c /^int fnum, no_intty, no_tty, slow_tty;$/;" v typeref:typename:int -no_tty bm_dos.c /^int no_intty, no_tty;$/;" v typeref:typename:int -no_tty bm_unix.c /^int fnum, no_intty, no_tty, slow_tty;$/;" v typeref:typename:int -noaddr comm.c /^char *noaddr = "No address allowed@on this command";$/;" v typeref:typename:char * -nobytes bvi.c /^char *nobytes = "No bytes@in the buffer";$/;" v typeref:typename:char * -nodelay doscur.h /^#define nodelay(/;" d -noecho doscur.h /^#define noecho(/;" d -nonl doscur.h /^#define nonl(/;" d -noprev re.c /^char *noprev = "No previous expression";$/;" v typeref:typename:char * -noraw doscur.h /^#define noraw(/;" d -normal bm_dos.c /^normal()$/;" f typeref:typename:void -normal bm_unix.c /^normal()$/;" f typeref:typename:void -notfound re.c /^char *notfound = "Fail|Pattern not found";$/;" v typeref:typename:char * -notimeout doscur.h /^#define notimeout(/;" d -noval comm.c /^char *noval = "No value@for binary operation";$/;" v typeref:typename:char * -nowrtmsg comm.c /^char *nowrtmsg = "No write@since last change (:%s! overrides)";$/;" v typeref:typename:char * -nstate bm_unix.c /^struct termios ostate, nstate;$/;" v typeref:struct:termios -numarr bmore.c /^char numarr[64]; \/* string for collecting number *\/$/;" v typeref:typename:char[64] -numarr bvi.c /^char numarr[MAXCMD+1]; \/* string for collecting number *\/$/;" v typeref:typename:char[] -numfiles bmore.c /^int numfiles; \/* number of input files *\/$/;" v typeref:typename:int -numfiles bvi.c /^int numfiles; \/* number of input files *\/$/;" v typeref:typename:int -nvalue set.h /^ off_t nvalue;$/;" m struct:param typeref:typename:off_t -off_t bmore.h /^# define off_t /;" d -off_t bvi.h /^# define off_t /;" d -oldbuf comm.c /^static char oldbuf[CMDSZ + 3]; \/** for :!! command **\/$/;" v typeref:typename:char[] file: -oldpos bmore.c /^off_t bytepos, oldpos;$/;" v typeref:typename:off_t -open_file bmore.c /^open_file(name)$/;" f +doshell bm_unix.c /^doshell(char *cmd)$/;" f +doupdate doscur.h 143;" d +dum_opt bm_unix.c /^int dum_opt, dlines;$/;" v +dup_print_flag bmore.c /^int dup_print_flag = 0;$/;" v +echo doscur.h 128;" d +edit edit.c /^edit(int mode)$/;" f +edits bvi.c /^int edits = 0;$/;" v +emptyclass bmore.c /^char *emptyclass = "Empty byte class '[]' or '[^]'";$/;" v +emptyclass re.c /^char *emptyclass = "Bad character class|Empty byte class '[]' or '[^]' cannot match";$/;" v +emsg bmore.c /^emsg(char *s)$/;" f +emsg comm.c /^emsg(char *s)$/;" f +end_addr comm.c /^PTR end_addr;$/;" v +end_word re.c /^end_word(PTR start)$/;" f +endwin doscur.h 137;" d +enlarge dosio.c /^enlarge(off_t add)$/;" f +enlarge io.c /^enlarge(off_t add)$/;" f +env bvi.c /^jmp_buf env; \/* context for `longjmp' function *\/$/;" v +erase doscur.h 81;" d +erase_ln bm_unix.c /^char *erase_ln; \/* erase line *\/$/;" v +erasechar doscur.h 75;" d +estring bmore.c /^char estring[MAXCMD] = ""; \/* string for shell escape *\/$/;" v +extra comm.c /^char *extra = "Extra chars|Extra characters at end of command";$/;" v +exval bmore.c /^int exval = 0;$/;" v +fbuf set.c /^static char fbuf[MAXCMD+1];$/;" v file: +ffp set.c /^static FILE *ffp;$/;" v file: +file_nr bmore.c /^int file_nr = 0; \/* number of current input file *\/$/;" v +fileinfo edit.c /^fileinfo(char *fname)$/;" f +filemode dosio.c /^int filemode;$/;" v +filemode io.c /^int filemode;$/;" v +files bmore.c /^char **files; \/* list of input files *\/$/;" v +files bvi.c /^char **files; \/* list of input files *\/$/;" v +filesize bmore.c /^off_t screen_home, filesize;$/;" v +filesize bvi.c /^off_t filesize, memsize, undosize;$/;" v +flags set.h /^ int flags;$/;" m struct:param +flash doscur.h 77;" d +flushinp doscur.h 120;" d +fname_buf bvi.c /^char *fname_buf = NULL;$/;" v +fnum bm_unix.c /^int fnum, no_intty, no_tty, slow_tty;$/;" v +from_file set.c /^static int from_file = 0;$/;" v file: +fsearch re.c /^fsearch(PTR start, PTR end, char *smem)$/;" f +fsearch_end re.c /^fsearch_end(PTR start, PTR end, char *smem, PTR *s_end)$/;" f +fullname set.h /^ char *fullname; \/* full parameter name *\/$/;" m struct:param +getbegyx doscur.h 105;" d +getcbuff edit.c /^static char getcbuff[BUFFER];$/;" v file: +getch dosio.c /^getch()$/;" f +getcmdstr set.c /^getcmdstr(char *p, int x)$/;" f +getcnext edit.c /^static char *getcnext = NULL;$/;" v file: +getmaxyx doscur.h 106;" d +getyx doscur.h 104;" d +got_int bm_dos.c /^int got_int;$/;" v +got_int bm_unix.c /^int got_int;$/;" v +help_file bmore.c /^FILE *curr_file = NULL, *help_file;$/;" v +helppath bmore.c /^char helppath[MAXCMD];$/;" v +hex_comp recomp.c /^hex_comp(char *smem, char *pattern)$/;" f +hexchar recomp.c /^hexchar()$/;" f +highlight bm_dos.c /^highlight()$/;" f +highlight bm_unix.c /^highlight()$/;" f +hl_spat edit.c /^long hl_spat = 0;$/;" v +home bm_dos.c /^home()$/;" f +home bm_unix.c /^home()$/;" f +icnt bmore.c /^static int icnt = 0;$/;" v file: +idlok doscur.h 141;" d +ignore_case recomp.c /^int ignore_case = 0;$/;" v +inch dosio.c /^inch()$/;" f +init_byte bmore.c /^off_t init_byte = 0;$/;" v +init_search bmore.c /^int init_search = 0;$/;" v +initscr doscur.h 73;" d +initterm bm_dos.c /^initterm()$/;" f +initterm bm_unix.c /^initterm()$/;" f +insch dosio.c /^insch(int c)$/;" f +insertln doscur.h 108;" d +jmpproc bvi.c /^jmpproc(int sig)$/;" f +keypad doscur.h 133;" d +last_motion bvi.c /^PTR last_motion;$/;" v +last_search bmore.c /^off_t last_search = 0;$/;" v +linbuf edit.c /^char linbuf[16384];$/;" v +line bvi.c /^static char line[MAXCMD+1];$/;" v file: +lineout edit.c /^lineout()$/;" f +load dosio.c /^load(char *fname)$/;" f +load io.c /^load(char *fname)$/;" f +loc bvi.c /^int loc;$/;" v +magic recomp.c /^int magic = 1;$/;" v +main bmore.c /^main(int argc, char *argv[])$/;" f +main bvi.c /^main(int argc, char *argv[])$/;" f +mark bvi.c /^static int mark;$/;" v file: +markbuf bvi.c /^PTR markbuf[26];$/;" v +maxpos bvi.c /^PTR maxpos;$/;" v +maxx bmore.c /^int maxx, maxy;$/;" v +maxx bvi.c /^int maxx, maxy, x, xx, y;$/;" v +maxy bmore.c /^int maxx, maxy;$/;" v +maxy bvi.c /^int maxx, maxy, x, xx, y;$/;" v +mem bvi.c /^PTR mem = NULL;$/;" v +memcpy bvi.h 136;" d +memmove bm_unix.c /^memmove(char *s1, char *s2, size_t n)$/;" f +memmove bvi.h 137;" d +memmove io.c /^memmove(char *s1, char *s2, size_t n)$/;" f +memsize bvi.c /^off_t filesize, memsize, undosize;$/;" v +morefiles comm.c /^char *morefiles = "more files@to edit";$/;" v +move doscur.h 91;" d +movebyte edit.c /^movebyte()$/;" f +msg comm.c /^msg(char *s)$/;" f +mvaddch doscur.h 93;" d +mvaddstr doscur.h 97;" d +mvgetch doscur.h 112;" d +mvgetstr doscur.h 115;" d +mvinch dosio.c /^mvinch(int y, int x)$/;" f +mvinsch doscur.h 125;" d +mvprintw doscur.h 101;" d +mvscanw doscur.h 122;" d +mvwaddch doscur.h 92;" d +mvwaddstr doscur.h 96;" d +mvwgetch doscur.h 111;" d +mvwgetstr doscur.h 114;" d +mvwprintw doscur.h 100;" d +mvwscanw doscur.h 121;" d +mymaxx bmore.c /^int mymaxx = 0, mymaxy = 0;$/;" v +mymaxy bmore.c /^int mymaxx = 0, mymaxy = 0;$/;" v +name bmore.c /^char *name = NULL;$/;" v +name bvi.c /^char *name = NULL;$/;" v +new_screen edit.c /^new_screen()$/;" f +newwin doscur.h 74;" d +nextchar bmore.c /^nextchar()$/;" f +nl doscur.h 131;" d +no_intty bm_dos.c /^int no_intty, no_tty;$/;" v +no_intty bm_unix.c /^int fnum, no_intty, no_tty, slow_tty;$/;" v +no_tty bm_dos.c /^int no_intty, no_tty;$/;" v +no_tty bm_unix.c /^int fnum, no_intty, no_tty, slow_tty;$/;" v +noaddr comm.c /^char *noaddr = "No address allowed@on this command";$/;" v +nobytes bvi.c /^char *nobytes = "No bytes@in the buffer";$/;" v +nodelay doscur.h 127;" d +noecho doscur.h 129;" d +nonl doscur.h 132;" d +noprev re.c /^char *noprev = "No previous expression";$/;" v +noraw doscur.h 139;" d +normal bm_dos.c /^normal()$/;" f +normal bm_unix.c /^normal()$/;" f +notfound re.c /^char *notfound = "Fail|Pattern not found";$/;" v +notimeout doscur.h 140;" d +noval comm.c /^char *noval = "No value@for binary operation";$/;" v +nowrtmsg comm.c /^char *nowrtmsg = "No write@since last change (:%s! overrides)";$/;" v +nstate bm_unix.c /^struct termios ostate, nstate;$/;" v typeref:struct: +numarr bmore.c /^char numarr[64]; \/* string for collecting number *\/$/;" v +numarr bvi.c /^char numarr[MAXCMD+1]; \/* string for collecting number *\/$/;" v +numfiles bmore.c /^int numfiles; \/* number of input files *\/$/;" v +numfiles bvi.c /^int numfiles; \/* number of input files *\/$/;" v +nvalue set.h /^ off_t nvalue;$/;" m struct:param +off_t bmore.h 110;" d +off_t bvi.h 132;" d +oldbuf comm.c /^static char oldbuf[CMDSZ + 3]; \/** for :!! command **\/$/;" v file: +oldpos bmore.c /^off_t bytepos, oldpos;$/;" v +open_file bmore.c /^open_file(char *name)$/;" f ostate bm_unix.c /^struct termios ostate, nstate;$/;" v typeref:struct:termios -out_len bmore.c /^int out_len;$/;" v typeref:typename:int -outmsg comm.c /^outmsg(s)$/;" f -pagepos bvi.c /^PTR pagepos;$/;" v typeref:typename:PTR +out_len bmore.c /^int out_len;$/;" v +outmsg comm.c /^outmsg(char *s)$/;" f +pagepos bvi.c /^PTR pagepos;$/;" v param set.h /^struct param {$/;" s -params set.c /^struct param params[] = {$/;" v typeref:struct:param[] -patcpy re.c /^patcpy(s1, s2, delim)$/;" f -pattern re.c /^char pattern[MAXCMD + 1];$/;" v typeref:typename:char[] -poi recomp.c /^char *poi;$/;" v typeref:typename:char * -precount bmore.c /^long precount = -1; \/* number preceding command *\/$/;" v typeref:typename:long -precount bvi.c /^long precount = -1;$/;" v typeref:typename:long -printline edit.c /^printline(mempos, scpos)$/;" f -printout bmore.c /^printout(lns)$/;" f -printw doscur.h /^#define printw /;" d -progname bmore.c /^static char progname[10];$/;" v typeref:typename:char[10] file: -progname bvi.c /^static char progname[8];$/;" v typeref:typename:char[8] file: -prompt bmore.c /^int prompt = 1;$/;" v typeref:typename:int -pushback bmore.c /^pushback(n, where)$/;" f -putchr bm_unix.c /^putchr(ch)$/;" f -putchr bm_unix.c /^putchr(char ch)$/;" f typeref:typename:int -putline bmore.c /^putline(buf, num)$/;" f -quit edit.c /^quit()$/;" f typeref:typename:void -r_flag bmore.c /^int c_flag = 0, d_flag = 0, r_flag = 0;$/;" v typeref:typename:int -range bvi.c /^range(ch)$/;" f -raw doscur.h /^#define raw(/;" d -rdline bmore.c /^rdline(ch, sstring)$/;" f -read_rc set.c /^read_rc(fn)$/;" f -read_to_end io.c /^read_to_end(int fd, void *buf, size_t count) {$/;" f typeref:typename:ssize_t file: -refresh doscur.h /^#define refresh(/;" d -rep_buf bvi.c /^char rep_buf[BUFFER];$/;" v typeref:typename:char[] -repaint edit.c /^repaint() \/***** redraw screen *********************\/$/;" f typeref:typename:void -repl_count comm.c /^int repl_count = -1;$/;" v typeref:typename:int -reset_tty bm_dos.c /^reset_tty ()$/;" f typeref:typename:void -reset_tty bm_unix.c /^reset_tty()$/;" f typeref:typename:void -resetty doscur.h /^#define resetty(/;" d -rev_end bm_unix.c /^char *rev_start, *rev_end; \/* enter and exit standout mode *\/$/;" v typeref:typename:char * -rev_start bm_unix.c /^char *rev_start, *rev_end; \/* enter and exit standout mode *\/$/;" v typeref:typename:char * -rsearch re.c /^rsearch(start, end, smem)$/;" f -save dosio.c /^save(char *fname, PTR start, PTR end, int flags)$/;" f typeref:typename:int -save io.c /^save(fname, start, end, flags)$/;" f -save_chk comm.c /^save_chk(fname, start, end, flags)$/;" f -savetty doscur.h /^#define savetty(/;" d -sbracket bmore.c /^sbracket(start, scan, count)$/;" f -sbracket re.c /^sbracket(start, scan, count)$/;" f file: -scanw doscur.h /^#define scanw /;" d +params set.c /^struct param params[] = {$/;" v typeref:struct:param +patcpy re.c /^patcpy(char *s1, char *s2, char delim)$/;" f +pattern re.c /^char pattern[MAXCMD + 1];$/;" v +poi recomp.c /^char *poi;$/;" v +precount bmore.c /^long precount = -1; \/* number preceding command *\/$/;" v +precount bvi.c /^long precount = -1;$/;" v +printline edit.c /^printline(PTR mempos, int scpos)$/;" f +printout bmore.c /^printout(int lns)$/;" f +printw doscur.h 103;" d +progname bmore.c /^static char progname[10];$/;" v file: +progname bvi.c /^static char progname[8];$/;" v file: +prompt bmore.c /^int prompt = 1;$/;" v +pushback bmore.c /^pushback(int n, char *where)$/;" f +putchr bm_unix.c /^putchr(char ch)$/;" f +putchr bm_unix.c /^putchr(int ch)$/;" f +putline bmore.c /^putline(char *buf, int num)$/;" f +quit edit.c /^quit()$/;" f +r_flag bmore.c /^int c_flag = 0, d_flag = 0, r_flag = 0;$/;" v +range bvi.c /^range(int ch)$/;" f +raw doscur.h 138;" d +rdline bmore.c /^rdline(int ch, char *sstring)$/;" f +read_rc set.c /^read_rc(char *fn)$/;" f +read_to_end io.c /^read_to_end(int fd, void *buf, size_t count) {$/;" f file: +refresh doscur.h 134;" d +rep_buf bvi.c /^char rep_buf[BUFFER];$/;" v +repaint edit.c /^repaint() \/***** redraw screen *********************\/$/;" f +repl_count comm.c /^int repl_count = -1;$/;" v +reset_tty bm_dos.c /^reset_tty ()$/;" f +reset_tty bm_unix.c /^reset_tty()$/;" f +resetty doscur.h 145;" d +rev_end bm_unix.c /^char *rev_start, *rev_end; \/* enter and exit standout mode *\/$/;" v +rev_start bm_unix.c /^char *rev_start, *rev_end; \/* enter and exit standout mode *\/$/;" v +rsearch re.c /^rsearch(PTR start, PTR end, char *smem)$/;" f +save dosio.c /^save(char *fname, PTR start, PTR end, int flags)$/;" f +save io.c /^save(char *fname, char *start, char *end, int flags)$/;" f +save_chk comm.c /^save_chk(char *fname, char *start, char *end, int flags)$/;" f +savetty doscur.h 144;" d +sbracket bmore.c /^sbracket(int start, char *scan, int count)$/;" f +sbracket re.c /^sbracket(int start, char *scan, int count)$/;" f file: +scanw doscur.h 124;" d scr dosio.c /^struct WINDOW scr;$/;" v typeref:struct:WINDOW -screen bvi.c /^int screen, status, statsize;$/;" v typeref:typename:int -screen_home bmore.c /^off_t screen_home, filesize;$/;" v typeref:typename:off_t -scrolldown edit.c /^scrolldown(lns)$/;" f -scrollok doscur.h /^#define scrollok(/;" d -scrollup edit.c /^scrollup(lns)$/;" f -search_pat re.c /^char search_pat[BUFFER]; \/* \/ or ? command *\/$/;" v typeref:typename:char[] -searching re.c /^searching(ch, line, startpos, endpos, flag)$/;" f -set_tty bm_dos.c /^set_tty ()$/;" f typeref:typename:void -set_tty bm_unix.c /^set_tty()$/;" f typeref:typename:void -setcur edit.c /^setcur()$/;" f typeref:typename:void -setpage edit.c /^setpage(addr)$/;" f -shell bvi.c /^char *shell;$/;" v typeref:typename:char * -shortname set.h /^ char *shortname; \/* permissible abbreviation *\/$/;" m struct:param typeref:typename:char * -showparms set.c /^showparms(all)$/;" f -sig bm_dos.c /^sig()$/;" f typeref:typename:void -sig bm_unix.c /^sig(sig)$/;" f -size bvi.c /^off_t size;$/;" v typeref:typename:off_t -slow_tty bm_unix.c /^int fnum, no_intty, no_tty, slow_tty;$/;" v typeref:typename:int -smode bmore.c /^static int smode;$/;" v typeref:typename:int file: -smode recomp.c /^int smode;$/;" v typeref:typename:int -smsg comm.c /^smsg(s)$/;" f -spos bvi.c /^PTR spos;$/;" v typeref:typename:PTR -sstring bmore.c /^char sstring[MAXCMD] = ""; \/* string for search *\/$/;" v typeref:typename:char[] -standend doscur.h /^#define standend(/;" d -standout doscur.h /^#define standout(/;" d -start_addr comm.c /^PTR start_addr;$/;" v typeref:typename:PTR -statpos edit.c /^statpos()$/;" f typeref:typename:void -statsize bvi.c /^int screen, status, statsize;$/;" v typeref:typename:int -status bvi.c /^int screen, status, statsize;$/;" v typeref:typename:int -stdscr dosio.c /^int stdscr = 0;$/;" v typeref:typename:int -strcasecmp bmore.h /^# define strcasecmp /;" d -strcasecmp bvi.h /^# define strcasecmp /;" d -strdup io.c /^strdup(s)$/;" f -string bmore.c /^char string[MAXCMD];$/;" v typeref:typename:char[] -string bvi.c /^char string[MAXCMD+1];$/;" v typeref:typename:char[] -strncasecmp bmore.h /^# define strncasecmp /;" d -strncasecmp bvi.h /^# define strncasecmp /;" d -stty bm_unix.c /^#define stty(/;" d file: -stuffin edit.c /^stuffin(s)$/;" f -svalue set.h /^ char *svalue;$/;" m struct:param typeref:typename:char * -sysemsg comm.c /^sysemsg(s)$/;" f -terminal dosio.c /^char *terminal = "ansi";$/;" v typeref:typename:char * -terminal io.c /^char *terminal;$/;" v typeref:typename:char * -tmpbuf edit.c /^char tmpbuf[10];$/;" v typeref:typename:char[10] -to_print bmore.c /^int corr = 0, do_header = 0, to_print;$/;" v typeref:typename:int -toggle edit.c /^toggle()$/;" f typeref:typename:void -trunc_cur bvi.c /^trunc_cur()$/;" f typeref:typename:void -undo_buf bvi.c /^char *undo_buf = NULL;$/;" v typeref:typename:char * -undo_count bvi.c /^off_t undo_count;$/;" v typeref:typename:off_t -undo_start bvi.c /^PTR undo_start;$/;" v typeref:typename:PTR -undosize bvi.c /^off_t filesize, memsize, undosize;$/;" v typeref:typename:off_t -usage bmore.c /^usage()$/;" f typeref:typename:void -usage bvi.c /^usage()$/;" f typeref:typename:void -vgetc bm_dos.c /^vgetc()$/;" f typeref:typename:int -vgetc bm_unix.c /^vgetc()$/;" f typeref:typename:int -vgetc edit.c /^vgetc()$/;" f typeref:typename:int -waddch doscur.h /^#define waddch(/;" d -waddstr doscur.h /^#define waddstr(/;" d -wait_return comm.c /^wait_return(flag)$/;" f -wclear doscur.h /^#define wclear(/;" d -wclrtoeol doscur.h /^#define wclrtoeol(/;" d -wdeleteln doscur.h /^#define wdeleteln(/;" d -werase doscur.h /^#define werase(/;" d -wgetch doscur.h /^#define wgetch(/;" d -wgetstr doscur.h /^#define wgetstr(/;" d -winsertln doscur.h /^#define winsertln(/;" d -wmove doscur.h /^#define wmove(/;" d -wordsearch re.c /^wordsearch(start, mode)$/;" f -wprintw doscur.h /^#define wprintw(/;" d -wrefresh doscur.h /^#define wrefresh(/;" d -wrstat bvi.c /^static int wrstat = 1;$/;" v typeref:typename:int file: -wscanw doscur.h /^#define wscanw(/;" d -x bvi.c /^int maxx, maxy, x, xx, y;$/;" v typeref:typename:int -xpos edit.c /^xpos()$/;" f typeref:typename:int -xx bvi.c /^int maxx, maxy, x, xx, y;$/;" v typeref:typename:int -y bvi.c /^int maxx, maxy, x, xx, y;$/;" v typeref:typename:int -yank_buf bvi.c /^char *yank_buf = NULL;$/;" v typeref:typename:char * -yanked bvi.c /^off_t yanked = 0L;$/;" v typeref:typename:off_t -yd_addr comm.c /^yd_addr()$/;" f typeref:typename:off_t +screen bvi.c /^int screen, status, statsize;$/;" v +screen_home bmore.c /^off_t screen_home, filesize;$/;" v +scrolldown edit.c /^scrolldown(int lns)$/;" f +scrollok doscur.h 142;" d +scrollup edit.c /^scrollup(int lns)$/;" f +search_pat re.c /^char search_pat[BUFFER]; \/* \/ or ? command *\/$/;" v +searching re.c /^searching(int ch, char *line, PTR startpos, PTR endpos, int flag)$/;" f +set_tty bm_dos.c /^set_tty ()$/;" f +set_tty bm_unix.c /^set_tty()$/;" f +setcur edit.c /^setcur()$/;" f +setpage edit.c /^setpage(PTR addr)$/;" f +shell bvi.c /^char *shell;$/;" v +shortname set.h /^ char *shortname; \/* permissible abbreviation *\/$/;" m struct:param +showparms set.c /^showparms(int all)$/;" f +sig bm_dos.c /^sig()$/;" f +sig bm_unix.c /^sig(int sig)$/;" f +size bvi.c /^off_t size;$/;" v +slow_tty bm_unix.c /^int fnum, no_intty, no_tty, slow_tty;$/;" v +smode bmore.c /^static int smode;$/;" v file: +smode recomp.c /^int smode;$/;" v +smsg comm.c /^smsg(char *s)$/;" f +space bvi.c /^int space = 2;$/;" v +spos bvi.c /^PTR spos;$/;" v +sstring bmore.c /^char sstring[MAXCMD] = ""; \/* string for search *\/$/;" v +standend doscur.h 89;" d +standout doscur.h 88;" d +start_addr comm.c /^PTR start_addr;$/;" v +statpos edit.c /^statpos()$/;" f +statsize bvi.c /^int screen, status, statsize;$/;" v +status bvi.c /^int screen, status, statsize;$/;" v +statusflag bvi.c /^int statusflag = 1;$/;" v +stdscr dosio.c /^int stdscr = 0;$/;" v +strcasecmp bmore.h 113;" d +strcasecmp bvi.h 135;" d +strdup io.c /^strdup(char *s)$/;" f +string bmore.c /^char string[MAXCMD];$/;" v +string bvi.c /^char string[MAXCMD+1];$/;" v +strncasecmp bmore.h 112;" d +strncasecmp bvi.h 134;" d +stty bm_unix.c 36;" d file: +stuffin edit.c /^stuffin(char *s)$/;" f +svalue set.h /^ char *svalue;$/;" m struct:param +sysemsg comm.c /^sysemsg(char *s)$/;" f +terminal dosio.c /^char *terminal = "ansi";$/;" v +terminal io.c /^char *terminal;$/;" v +tmpbuf edit.c /^char tmpbuf[10];$/;" v +to_print bmore.c /^int corr = 0, do_header = 0, to_print;$/;" v +toggle edit.c /^toggle()$/;" f +trunc_cur bvi.c /^trunc_cur()$/;" f +undo_buf bvi.c /^char *undo_buf = NULL;$/;" v +undo_count bvi.c /^off_t undo_count;$/;" v +undo_start bvi.c /^PTR undo_start;$/;" v +undosize bvi.c /^off_t filesize, memsize, undosize;$/;" v +usage bmore.c /^usage()$/;" f +usage bvi.c /^usage()$/;" f +vgetc bm_dos.c /^vgetc()$/;" f +vgetc bm_unix.c /^vgetc()$/;" f +vgetc edit.c /^vgetc()$/;" f +waddch doscur.h 94;" d +waddstr doscur.h 98;" d +wait_return comm.c /^wait_return(int flag)$/;" f +wclear doscur.h 82;" d +wclrtoeol doscur.h 78;" d +wdeleteln doscur.h 109;" d +werase doscur.h 80;" d +wgetch doscur.h 113;" d +wgetstr doscur.h 116;" d +winsertln doscur.h 107;" d +wmove doscur.h 90;" d +wordsearch re.c /^wordsearch(PTR start, char mode)$/;" f +wprintw doscur.h 102;" d +wrefresh doscur.h 135;" d +wrstat bvi.c /^static int wrstat = 1;$/;" v file: +wscanw doscur.h 123;" d +x bvi.c /^int maxx, maxy, x, xx, y;$/;" v +xpos edit.c /^xpos()$/;" f +xx bvi.c /^int maxx, maxy, x, xx, y;$/;" v +y bvi.c /^int maxx, maxy, x, xx, y;$/;" v +yank_buf bvi.c /^char *yank_buf = NULL;$/;" v +yanked bvi.c /^off_t yanked = 0L;$/;" v +yd_addr comm.c /^yd_addr()$/;" f