Flush out the last dregs in the terminal before quitting when
[unix-history] / usr / src / usr.bin / ex / ex_data.c
CommitLineData
19d73a0e
DF
1/*
2 * Copyright (c) 1980 Regents of the University of California.
3 * All rights reserved. The Berkeley software License Agreement
4 * specifies the terms and conditions for redistribution.
5 */
6
7#ifndef lint
5a6c967e 8static char *sccsid = "@(#)ex_data.c 7.6 (Berkeley) %G%";
19d73a0e
DF
9#endif not lint
10
e9a419e5
MH
11#include "ex.h"
12#include "ex_tty.h"
13
14/*
15 * Initialization of option values.
16 * The option #defines in ex_vars.h are made
17 * from this file by the script makeoptions.
887e3e0d
MH
18 *
19 * These initializations are done char by char instead of as strings
20 * to confuse xstr so it will leave them alone.
e9a419e5 21 */
887e3e0d 22char direct[ONMSZ] =
5a6c967e
CH
23#ifdef vms
24 {'t', 'm', 'p', ':'};
25#else
299f2784 26 {'/', 't', 'm', 'p'};
5a6c967e 27#endif
887e3e0d 28char paragraphs[ONMSZ] = {
e9a419e5
MH
29 'I', 'P', 'L', 'P', 'P', 'P', 'Q', 'P', /* -ms macros */
30 'P', ' ', 'L', 'I', /* -mm macros */
299f2784 31 'p', 'p', 'l', 'p', 'i', 'p', /* -me macros */
e9a419e5
MH
32 'b', 'p' /* bare nroff */
33};
887e3e0d
MH
34char sections[ONMSZ] = {
35 'N', 'H', 'S', 'H', /* -ms macros */
299f2784
MH
36 'H', ' ', 'H', 'U', /* -mm macros */
37 'n', 'h', 's', 'h' /* -me macros */
887e3e0d
MH
38};
39char shell[ONMSZ] =
e9a419e5 40 { '/', 'b', 'i', 'n', '/', 's', 'h' };
887e3e0d
MH
41char tags[ONMSZ] = {
42 't', 'a', 'g', 's', ' ',
43 '/', 'u', 's', 'r', '/', 'l', 'i', 'b', '/', 't', 'a', 'g', 's'
44};
45char ttytype[ONMSZ] =
e9a419e5
MH
46 { 'd', 'u', 'm', 'b' };
47
48short COLUMNS = 80;
49short LINES = 24;
50
51struct option options[NOPTS + 1] = {
52 "autoindent", "ai", ONOFF, 0, 0, 0,
53 "autoprint", "ap", ONOFF, 1, 1, 0,
54 "autowrite", "aw", ONOFF, 0, 0, 0,
55 "beautify", "bf", ONOFF, 0, 0, 0,
56 "directory", "dir", STRING, 0, 0, direct,
57 "edcompatible", "ed", ONOFF, 0, 0, 0,
58 "errorbells", "eb", ONOFF, 0, 0, 0,
59 "hardtabs", "ht", NUMERIC, 8, 8, 0,
60 "ignorecase", "ic", ONOFF, 0, 0, 0,
5a6c967e
CH
61#ifndef UNIX_SBRK
62 "linelimit", "ll", NUMERIC, 2000, 2000, 0,
63#endif
e9a419e5
MH
64 "lisp", 0, ONOFF, 0, 0, 0,
65 "list", 0, ONOFF, 0, 0, 0,
e9a419e5 66 "magic", 0, ONOFF, 1, 1, 0,
d266c416 67 "mesg", 0, ONOFF, 1, 1, 0,
f6e8a45e 68 "modeline", 0, ONOFF, 0, 0, 0,
e9a419e5
MH
69 "number", "nu", ONOFF, 0, 0, 0,
70 "open", 0, ONOFF, 1, 1, 0,
71 "optimize", "opt", ONOFF, 0, 0, 0,
72 "paragraphs", "para", STRING, 0, 0, paragraphs,
73 "prompt", 0, ONOFF, 1, 1, 0,
d266c416 74 "readonly", "ro", ONOFF, 0, 0, 0,
e9a419e5 75 "redraw", 0, ONOFF, 0, 0, 0,
887e3e0d 76 "remap", 0, ONOFF, 1, 1, 0,
e9a419e5
MH
77 "report", 0, NUMERIC, 5, 5, 0,
78 "scroll", "scr", NUMERIC, 12, 12, 0,
79 "sections", "sect", STRING, 0, 0, sections,
80 "shell", "sh", STRING, 0, 0, shell,
81 "shiftwidth", "sw", NUMERIC, TABS, TABS, 0,
82 "showmatch", "sm", ONOFF, 0, 0, 0,
83 "slowopen", "slow", ONOFF, 0, 0, 0,
54869f35 84 "sourceany", 0, ONOFF, 0, 0, 0,
e9a419e5 85 "tabstop", "ts", NUMERIC, TABS, TABS, 0,
d266c416
MH
86 "taglength", "tl", NUMERIC, 0, 0, 0,
87 "tags", "tag", STRING, 0, 0, tags,
e9a419e5
MH
88 "term", 0, OTERM, 0, 0, ttytype,
89 "terse", 0, ONOFF, 0, 0, 0,
887e3e0d
MH
90 "timeout", "to", ONOFF, 1, 1, 0,
91 "ttytype", "tty", OTERM, 0, 0, ttytype,
e9a419e5
MH
92 "warn", 0, ONOFF, 1, 1, 0,
93 "window", "wi", NUMERIC, 23, 23, 0,
94 "wrapscan", "ws", ONOFF, 1, 1, 0,
95 "wrapmargin", "wm", NUMERIC, 0, 0, 0,
96 "writeany", "wa", ONOFF, 0, 0, 0,
97 0, 0, 0, 0, 0, 0,
98};