.HP 5
.na
.B mhl
-.RB [ \-bell " | " \-nobell ]
.RB [ \-clear " | " \-noclear ]
.RB [ \-folder
.IR +folder ]
CTRL-\\) will terminate the program (without core dump).
.PP
The
-.B \-bell
-option tells
-.B mhl
-to ring the terminal's bell at the
-end of each page, while the
.B \-clear
option tells
.B mhl
to clear the
screen at the end of each page (or output a formfeed after each message).
-Both of these switches (and their inverse counterparts) take effect only
+This switches (and its inverse counterpart) take effect only
if the profile entry
.I moreproc
is defined but empty, and
affect is global. Since the whole format is parsed before any output
processing, the last global switch setting for a variable applies to
the whole message if that variable is used in a global context (i.e.,
-bell, clearscreen, width, length).
+clearscreen, width, length).
.PP
.RS 5
.nf
nouppercase flag don't uppercase
clearscreen flag/G clear the screen prior to each page
noclearscreen flag/G don't clearscreen
-bell flag/G ring the bell at the end of each page
-nobell flag/G don't bell
component string/L name to use instead of \*(lqcomponent\*(rq for
this component
nocomponent flag don't output \*(lqcomponent: \*(rq for this
.SH DEFAULTS
.nf
-.RB ` \-bell '
.RB ` \-noclear '
.RB ` \-length 40 '
.RB ` \-width 80 '
switch does only take file names, but no format strings with a prepended
equal sign `='.
.PP
-There should be some way to pass `bell' and `clear' information to the
+There should be some way to pass `clear' information to the
front\-end.
.PP
The \*(lqnonewline\*(rq option interacts badly with \*(lqcompress\*(rq
#define QUOTE '\\'
static struct swit mhlswitches[] = {
-#define BELLSW 0
- { "bell", 0 },
-#define NBELLSW 1
- { "nobell", 0 },
-#define CLRSW 2
+#define CLRSW 0
{ "clear", 0 },
-#define NCLRSW 3
+#define NCLRSW 1
{ "noclear", 0 },
-#define FOLDSW 4
+#define FOLDSW 2
{ "folder +folder", 0 },
-#define FORMSW 5
+#define FORMSW 3
{ "form formfile", 0 },
-#define PROGSW 6
+#define PROGSW 4
{ "moreproc program", 0 },
-#define LENSW 7
+#define LENSW 5
{ "length lines", 0 },
-#define WIDTHSW 8
+#define WIDTHSW 6
{ "width columns", 0 },
-#define SLEEPSW 9
+#define SLEEPSW 7
{ "sleep seconds", 0 },
-#define VERSIONSW 10
+#define VERSIONSW 8
{ "version", 0 },
-#define HELPSW 11
+#define HELPSW 9
{ "help", 0 },
-#define FORW1SW 12
+#define FORW1SW 10
{ "forward", -7 },
-#define FORW2SW 13
+#define FORW2SW 11
{ "forwall", -7 },
-#define DGSTSW 14
+#define DGSTSW 12
{ "digest list", -6 },
-#define VOLUMSW 15
+#define VOLUMSW 13
{ "volume number", -6 },
-#define ISSUESW 16
+#define ISSUESW 14
{ "issue number", -5 },
-#define NBODYSW 17
+#define NBODYSW 15
{ "nobody", -6 },
{ NULL, 0 }
};
#define LEFTADJUST 0x000080 /* left justify multiple lines */
#define COMPRESS 0x000100 /* compress text */
#define ADDRFMT 0x000200 /* contains addresses */
-#define BELL 0x000400 /* sound bell at EOP */
-#define DATEFMT 0x000800 /* contains dates */
-#define FORMAT 0x001000 /* parse address/date/RFC-2047 field */
-#define INIT 0x002000 /* initialize component */
-#define SPLIT 0x004000 /* split headers (don't concatenate) */
-#define NONEWLINE 0x008000 /* don't write trailing newline */
-#define LBITS "\020\01NOCOMPONENT\02UPPERCASE\03CENTER\04CLEARTEXT\05EXTRA\06HDROUTPUT\07CLEARSCR\010LEFTADJUST\011COMPRESS\012ADDRFMT\013BELL\014DATEFMT\015FORMAT\016INIT\017SPLIT\020NONEWLINE"
+#define DATEFMT 0x000400 /* contains dates */
+#define FORMAT 0x000800 /* parse address/date/RFC-2047 field */
+#define INIT 0x001000 /* initialize component */
+#define SPLIT 0x002000 /* split headers (don't concatenate) */
+#define NONEWLINE 0x004000 /* don't write trailing newline */
+#define LBITS "\020\01NOCOMPONENT\02UPPERCASE\03CENTER\04CLEARTEXT\05EXTRA\06HDROUTPUT\07CLEARSCR\010LEFTADJUST\011COMPRESS\012ADDRFMT\013DATEFMT\014FORMAT\015INIT\016SPLIT\017NONEWLINE"
#define GFLAGS (NOCOMPONENT | UPPERCASE | CENTER | LEFTADJUST | COMPRESS | SPLIT)
struct mcomp {
static struct mcomp *fmttl = NULL;
static struct mcomp global = {
- NULL, NULL, "", NULL, NULL, 0, -1, 80, -1, 40, BELL, 0
+ NULL, NULL, "", NULL, NULL, 0, -1, 80, -1, 40, 0, 0
};
static struct mcomp holder = {
{ "split", SPLIT, 0 },
{ "nosplit", 0, SPLIT },
{ "addrfield", ADDRFMT, DATEFMT },
- { "bell", BELL, 0 },
- { "nobell", 0, BELL },
{ "datefield", DATEFMT, ADDRFMT },
{ "newline", 0, NONEWLINE },
{ "nonewline", NONEWLINE, 0 },
};
-static int bellflg = 0;
static int clearflg = 0;
static int dobody = 1;
static int forwflg = 0;
print_version(invo_name);
done(1);
- case BELLSW:
- bellflg = 1;
- continue;
- case NBELLSW:
- bellflg = -1;
- continue;
-
case CLRSW:
clearflg = 1;
continue;
global.c_cwidth = -1;
if ((i = sc_length()) > 5)
global.c_length = i - 1;
- global.c_flags = BELL; /* BELL is default */
+ global.c_flags = 0;
*(ip = ignores) = NULL;
while (vfgets(fp, &ap) == OK) {
global.c_flags &= ~CLEARSCR;
}
- switch (bellflg) { /* command line may override format file */
- case 1:
- global.c_flags |= BELL;
- break;
- case -1:
- global.c_flags &= ~BELL;
- break;
- }
-
if (length)
global.c_length = length;
if (width)
row++;
if (row != global.c_length)
break;
- if (global.c_flags & BELL)
- putchar('\007');
fflush(stdout);
buf[0] = 0;
read(fileno(stdout), buf, sizeof(buf));