diff options
author | Devin J. Pohly <djpohly@gmail.com> | 2017-10-17 15:21:04 -0500 |
---|---|---|
committer | Devin J. Pohly <djpohly@gmail.com> | 2018-02-25 21:53:24 -0600 |
commit | 65976c1a29f2945c3cfb6af74cd6440cf193021d (patch) | |
tree | 670d2b3063767c1363322d6db5e73447e682081a | |
parent | 32d3b1d00f66eda4f5446f3b32cabed2c9a77a40 (diff) | |
download | st-patched-65976c1a29f2945c3cfb6af74cd6440cf193021d.tar.bz2 st-patched-65976c1a29f2945c3cfb6af74cd6440cf193021d.tar.xz st-patched-65976c1a29f2945c3cfb6af74cd6440cf193021d.zip |
Move config.h include from st.c to x.c
config.h includes references to KeySyms and other X stuff. Until we
come up with a cleaner way to separate configuration, it is simpler
(leads to more code removal) to have this here.
Signed-off-by: Devin J. Pohly <djpohly@gmail.com>
-rw-r--r-- | config.def.h | 73 | ||||
-rw-r--r-- | st.c | 47 | ||||
-rw-r--r-- | st.h | 50 | ||||
-rw-r--r-- | win.h | 3 | ||||
-rw-r--r-- | x.c | 37 |
5 files changed, 91 insertions, 119 deletions
diff --git a/config.def.h b/config.def.h index 18cb31c..1c181ab 100644 --- a/config.def.h +++ b/config.def.h | |||
@@ -5,8 +5,8 @@ | |||
5 | * | 5 | * |
6 | * font: see http://freedesktop.org/software/fontconfig/fontconfig-user.html | 6 | * font: see http://freedesktop.org/software/fontconfig/fontconfig-user.html |
7 | */ | 7 | */ |
8 | char font[] = "Liberation Mono:pixelsize=12:antialias=true:autohint=true"; | 8 | static char *font = "Liberation Mono:pixelsize=12:antialias=true:autohint=true"; |
9 | int borderpx = 2; | 9 | static int borderpx = 2; |
10 | 10 | ||
11 | /* | 11 | /* |
12 | * What program is execed by st depends of these precedence rules: | 12 | * What program is execed by st depends of these precedence rules: |
@@ -16,54 +16,54 @@ int borderpx = 2; | |||
16 | * 4: value of shell in /etc/passwd | 16 | * 4: value of shell in /etc/passwd |
17 | * 5: value of shell in config.h | 17 | * 5: value of shell in config.h |
18 | */ | 18 | */ |
19 | static char shell[] = "/bin/sh"; | 19 | char *shell = "/bin/sh"; |
20 | static char *utmp = NULL; | 20 | char *utmp = NULL; |
21 | static char stty_args[] = "stty raw pass8 nl -echo -iexten -cstopb 38400"; | 21 | char *stty_args = "stty raw pass8 nl -echo -iexten -cstopb 38400"; |
22 | 22 | ||
23 | /* identification sequence returned in DA and DECID */ | 23 | /* identification sequence returned in DA and DECID */ |
24 | static char vtiden[] = "\033[?6c"; | 24 | char *vtiden = "\033[?6c"; |
25 | 25 | ||
26 | /* Kerning / character bounding-box multipliers */ | 26 | /* Kerning / character bounding-box multipliers */ |
27 | float cwscale = 1.0; | 27 | static float cwscale = 1.0; |
28 | float chscale = 1.0; | 28 | static float chscale = 1.0; |
29 | 29 | ||
30 | /* | 30 | /* |
31 | * word delimiter string | 31 | * word delimiter string |
32 | * | 32 | * |
33 | * More advanced example: " `'\"()[]{}" | 33 | * More advanced example: " `'\"()[]{}" |
34 | */ | 34 | */ |
35 | static char worddelimiters[] = " "; | 35 | char *worddelimiters = " "; |
36 | 36 | ||
37 | /* selection timeouts (in milliseconds) */ | 37 | /* selection timeouts (in milliseconds) */ |
38 | unsigned int doubleclicktimeout = 300; | 38 | static unsigned int doubleclicktimeout = 300; |
39 | unsigned int tripleclicktimeout = 600; | 39 | static unsigned int tripleclicktimeout = 600; |
40 | 40 | ||
41 | /* alt screens */ | 41 | /* alt screens */ |
42 | int allowaltscreen = 1; | 42 | int allowaltscreen = 1; |
43 | 43 | ||
44 | /* frames per second st should at maximum draw to the screen */ | 44 | /* frames per second st should at maximum draw to the screen */ |
45 | unsigned int xfps = 120; | 45 | static unsigned int xfps = 120; |
46 | unsigned int actionfps = 30; | 46 | static unsigned int actionfps = 30; |
47 | 47 | ||
48 | /* | 48 | /* |
49 | * blinking timeout (set to 0 to disable blinking) for the terminal blinking | 49 | * blinking timeout (set to 0 to disable blinking) for the terminal blinking |
50 | * attribute. | 50 | * attribute. |
51 | */ | 51 | */ |
52 | unsigned int blinktimeout = 800; | 52 | static unsigned int blinktimeout = 800; |
53 | 53 | ||
54 | /* | 54 | /* |
55 | * thickness of underline and bar cursors | 55 | * thickness of underline and bar cursors |
56 | */ | 56 | */ |
57 | unsigned int cursorthickness = 2; | 57 | static unsigned int cursorthickness = 2; |
58 | 58 | ||
59 | /* | 59 | /* |
60 | * bell volume. It must be a value between -100 and 100. Use 0 for disabling | 60 | * bell volume. It must be a value between -100 and 100. Use 0 for disabling |
61 | * it | 61 | * it |
62 | */ | 62 | */ |
63 | int bellvolume = 0; | 63 | static int bellvolume = 0; |
64 | 64 | ||
65 | /* default TERM value */ | 65 | /* default TERM value */ |
66 | char termname[] = "st-256color"; | 66 | char *termname = "st-256color"; |
67 | 67 | ||
68 | /* | 68 | /* |
69 | * spaces per tab | 69 | * spaces per tab |
@@ -80,10 +80,10 @@ char termname[] = "st-256color"; | |||
80 | * | 80 | * |
81 | * stty tabs | 81 | * stty tabs |
82 | */ | 82 | */ |
83 | static unsigned int tabspaces = 8; | 83 | unsigned int tabspaces = 8; |
84 | 84 | ||
85 | /* Terminal colors (16 first used in escape sequence) */ | 85 | /* Terminal colors (16 first used in escape sequence) */ |
86 | const char *colorname[] = { | 86 | static const char *colorname[] = { |
87 | /* 8 normal colors */ | 87 | /* 8 normal colors */ |
88 | "black", | 88 | "black", |
89 | "red3", | 89 | "red3", |
@@ -118,8 +118,8 @@ const char *colorname[] = { | |||
118 | */ | 118 | */ |
119 | unsigned int defaultfg = 7; | 119 | unsigned int defaultfg = 7; |
120 | unsigned int defaultbg = 0; | 120 | unsigned int defaultbg = 0; |
121 | unsigned int defaultcs = 256; | 121 | static unsigned int defaultcs = 256; |
122 | unsigned int defaultrcs = 257; | 122 | static unsigned int defaultrcs = 257; |
123 | 123 | ||
124 | /* | 124 | /* |
125 | * Default shape of cursor | 125 | * Default shape of cursor |
@@ -128,33 +128,33 @@ unsigned int defaultrcs = 257; | |||
128 | * 6: Bar ("|") | 128 | * 6: Bar ("|") |
129 | * 7: Snowman ("☃") | 129 | * 7: Snowman ("☃") |
130 | */ | 130 | */ |
131 | unsigned int cursorshape = 2; | 131 | static unsigned int cursorshape = 2; |
132 | 132 | ||
133 | /* | 133 | /* |
134 | * Default columns and rows numbers | 134 | * Default columns and rows numbers |
135 | */ | 135 | */ |
136 | 136 | ||
137 | unsigned int cols = 80; | 137 | static unsigned int cols = 80; |
138 | unsigned int rows = 24; | 138 | static unsigned int rows = 24; |
139 | 139 | ||
140 | /* | 140 | /* |
141 | * Default colour and shape of the mouse cursor | 141 | * Default colour and shape of the mouse cursor |
142 | */ | 142 | */ |
143 | unsigned int mouseshape = XC_xterm; | 143 | static unsigned int mouseshape = XC_xterm; |
144 | unsigned int mousefg = 7; | 144 | static unsigned int mousefg = 7; |
145 | unsigned int mousebg = 0; | 145 | static unsigned int mousebg = 0; |
146 | 146 | ||
147 | /* | 147 | /* |
148 | * Color used to display font attributes when fontconfig selected a font which | 148 | * Color used to display font attributes when fontconfig selected a font which |
149 | * doesn't match the ones requested. | 149 | * doesn't match the ones requested. |
150 | */ | 150 | */ |
151 | unsigned int defaultattr = 11; | 151 | static unsigned int defaultattr = 11; |
152 | 152 | ||
153 | /* | 153 | /* |
154 | * Internal mouse shortcuts. | 154 | * Internal mouse shortcuts. |
155 | * Beware that overloading Button1 will disable the selection. | 155 | * Beware that overloading Button1 will disable the selection. |
156 | */ | 156 | */ |
157 | MouseShortcut mshortcuts[] = { | 157 | static MouseShortcut mshortcuts[] = { |
158 | /* button mask string */ | 158 | /* button mask string */ |
159 | { Button4, XK_ANY_MOD, "\031" }, | 159 | { Button4, XK_ANY_MOD, "\031" }, |
160 | { Button5, XK_ANY_MOD, "\005" }, | 160 | { Button5, XK_ANY_MOD, "\005" }, |
@@ -164,7 +164,7 @@ MouseShortcut mshortcuts[] = { | |||
164 | #define MODKEY Mod1Mask | 164 | #define MODKEY Mod1Mask |
165 | #define TERMMOD (ControlMask|ShiftMask) | 165 | #define TERMMOD (ControlMask|ShiftMask) |
166 | 166 | ||
167 | Shortcut shortcuts[] = { | 167 | static Shortcut shortcuts[] = { |
168 | /* mask keysym function argument */ | 168 | /* mask keysym function argument */ |
169 | { XK_ANY_MOD, XK_Break, sendbreak, {.i = 0} }, | 169 | { XK_ANY_MOD, XK_Break, sendbreak, {.i = 0} }, |
170 | { ControlMask, XK_Print, toggleprinter, {.i = 0} }, | 170 | { ControlMask, XK_Print, toggleprinter, {.i = 0} }, |
@@ -209,26 +209,26 @@ Shortcut shortcuts[] = { | |||
209 | * If you want keys other than the X11 function keys (0xFD00 - 0xFFFF) | 209 | * If you want keys other than the X11 function keys (0xFD00 - 0xFFFF) |
210 | * to be mapped below, add them to this array. | 210 | * to be mapped below, add them to this array. |
211 | */ | 211 | */ |
212 | KeySym mappedkeys[] = { -1 }; | 212 | static KeySym mappedkeys[] = { -1 }; |
213 | 213 | ||
214 | /* | 214 | /* |
215 | * State bits to ignore when matching key or button events. By default, | 215 | * State bits to ignore when matching key or button events. By default, |
216 | * numlock (Mod2Mask) and keyboard layout (XK_SWITCH_MOD) are ignored. | 216 | * numlock (Mod2Mask) and keyboard layout (XK_SWITCH_MOD) are ignored. |
217 | */ | 217 | */ |
218 | uint ignoremod = Mod2Mask|XK_SWITCH_MOD; | 218 | static uint ignoremod = Mod2Mask|XK_SWITCH_MOD; |
219 | 219 | ||
220 | /* | 220 | /* |
221 | * Override mouse-select while mask is active (when MODE_MOUSE is set). | 221 | * Override mouse-select while mask is active (when MODE_MOUSE is set). |
222 | * Note that if you want to use ShiftMask with selmasks, set this to an other | 222 | * Note that if you want to use ShiftMask with selmasks, set this to an other |
223 | * modifier, set to 0 to not use it. | 223 | * modifier, set to 0 to not use it. |
224 | */ | 224 | */ |
225 | uint forceselmod = ShiftMask; | 225 | static uint forceselmod = ShiftMask; |
226 | 226 | ||
227 | /* | 227 | /* |
228 | * This is the huge key array which defines all compatibility to the Linux | 228 | * This is the huge key array which defines all compatibility to the Linux |
229 | * world. Please decide about changes wisely. | 229 | * world. Please decide about changes wisely. |
230 | */ | 230 | */ |
231 | Key key[] = { | 231 | static Key key[] = { |
232 | /* keysym mask string appkey appcursor crlf */ | 232 | /* keysym mask string appkey appcursor crlf */ |
233 | { XK_KP_Home, ShiftMask, "\033[2J", 0, -1, 0}, | 233 | { XK_KP_Home, ShiftMask, "\033[2J", 0, -1, 0}, |
234 | { XK_KP_Home, ShiftMask, "\033[1;2H", 0, +1, 0}, | 234 | { XK_KP_Home, ShiftMask, "\033[1;2H", 0, +1, 0}, |
@@ -451,7 +451,7 @@ Key key[] = { | |||
451 | * ButtonRelease and MotionNotify. | 451 | * ButtonRelease and MotionNotify. |
452 | * If no match is found, regular selection is used. | 452 | * If no match is found, regular selection is used. |
453 | */ | 453 | */ |
454 | uint selmasks[] = { | 454 | static uint selmasks[] = { |
455 | [SEL_RECTANGULAR] = Mod1Mask, | 455 | [SEL_RECTANGULAR] = Mod1Mask, |
456 | }; | 456 | }; |
457 | 457 | ||
@@ -459,8 +459,7 @@ uint selmasks[] = { | |||
459 | * Printable characters in ASCII, used to estimate the advance width | 459 | * Printable characters in ASCII, used to estimate the advance width |
460 | * of single wide characters. | 460 | * of single wide characters. |
461 | */ | 461 | */ |
462 | char ascii_printable[] = | 462 | static char ascii_printable[] = |
463 | " !\"#$%&'()*+,-./0123456789:;<=>?" | 463 | " !\"#$%&'()*+,-./0123456789:;<=>?" |
464 | "@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_" | 464 | "@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_" |
465 | "`abcdefghijklmnopqrstuvwxyz{|}~"; | 465 | "`abcdefghijklmnopqrstuvwxyz{|}~"; |
466 | |||
@@ -109,19 +109,6 @@ typedef struct { | |||
109 | int narg; /* nb of args */ | 109 | int narg; /* nb of args */ |
110 | } STREscape; | 110 | } STREscape; |
111 | 111 | ||
112 | /* function definitions used in config.h */ | ||
113 | static void clipcopy(const Arg *); | ||
114 | static void clippaste(const Arg *); | ||
115 | static void numlock(const Arg *); | ||
116 | static void selpaste(const Arg *); | ||
117 | static void printsel(const Arg *); | ||
118 | static void printscreen(const Arg *) ; | ||
119 | static void iso14755(const Arg *); | ||
120 | static void toggleprinter(const Arg *); | ||
121 | static void sendbreak(const Arg *); | ||
122 | |||
123 | /* config.h for applying patches and the configuration. */ | ||
124 | #include "config.h" | ||
125 | 112 | ||
126 | static void execsh(char **); | 113 | static void execsh(char **); |
127 | static void stty(char **); | 114 | static void stty(char **); |
@@ -199,14 +186,6 @@ static uchar utfmask[UTF_SIZ + 1] = {0xC0, 0x80, 0xE0, 0xF0, 0xF8}; | |||
199 | static Rune utfmin[UTF_SIZ + 1] = { 0, 0, 0x80, 0x800, 0x10000}; | 186 | static Rune utfmin[UTF_SIZ + 1] = { 0, 0, 0x80, 0x800, 0x10000}; |
200 | static Rune utfmax[UTF_SIZ + 1] = {0x10FFFF, 0x7F, 0x7FF, 0xFFFF, 0x10FFFF}; | 187 | static Rune utfmax[UTF_SIZ + 1] = {0x10FFFF, 0x7F, 0x7FF, 0xFFFF, 0x10FFFF}; |
201 | 188 | ||
202 | /* config.h array lengths */ | ||
203 | size_t colornamelen = LEN(colorname); | ||
204 | size_t mshortcutslen = LEN(mshortcuts); | ||
205 | size_t shortcutslen = LEN(shortcuts); | ||
206 | size_t selmaskslen = LEN(selmasks); | ||
207 | size_t keyslen = LEN(key); | ||
208 | size_t mappedkeyslen = LEN(mappedkeys); | ||
209 | |||
210 | ssize_t | 189 | ssize_t |
211 | xwrite(int fd, const char *s, size_t len) | 190 | xwrite(int fd, const char *s, size_t len) |
212 | { | 191 | { |
@@ -586,24 +565,6 @@ getsel(void) | |||
586 | } | 565 | } |
587 | 566 | ||
588 | void | 567 | void |
589 | selpaste(const Arg *dummy) | ||
590 | { | ||
591 | xselpaste(); | ||
592 | } | ||
593 | |||
594 | void | ||
595 | clipcopy(const Arg *dummy) | ||
596 | { | ||
597 | xclipcopy(); | ||
598 | } | ||
599 | |||
600 | void | ||
601 | clippaste(const Arg *dummy) | ||
602 | { | ||
603 | xclippaste(); | ||
604 | } | ||
605 | |||
606 | void | ||
607 | selclear(void) | 568 | selclear(void) |
608 | { | 569 | { |
609 | if (sel.ob.x == -1) | 570 | if (sel.ob.x == -1) |
@@ -1572,7 +1533,7 @@ csihandle(void) | |||
1572 | break; | 1533 | break; |
1573 | case 'c': /* DA -- Device Attributes */ | 1534 | case 'c': /* DA -- Device Attributes */ |
1574 | if (csiescseq.arg[0] == 0) | 1535 | if (csiescseq.arg[0] == 0) |
1575 | ttywrite(vtiden, sizeof(vtiden) - 1); | 1536 | ttywrite(vtiden, strlen(vtiden)); |
1576 | break; | 1537 | break; |
1577 | case 'C': /* CUF -- Cursor <n> Forward */ | 1538 | case 'C': /* CUF -- Cursor <n> Forward */ |
1578 | case 'a': /* HPR -- Cursor <n> Forward */ | 1539 | case 'a': /* HPR -- Cursor <n> Forward */ |
@@ -1791,7 +1752,7 @@ strhandle(void) | |||
1791 | dec = base64dec(strescseq.args[2]); | 1752 | dec = base64dec(strescseq.args[2]); |
1792 | if (dec) { | 1753 | if (dec) { |
1793 | xsetsel(dec, CurrentTime); | 1754 | xsetsel(dec, CurrentTime); |
1794 | clipcopy(NULL); | 1755 | xclipcopy(); |
1795 | } else { | 1756 | } else { |
1796 | fprintf(stderr, "erresc: invalid base64\n"); | 1757 | fprintf(stderr, "erresc: invalid base64\n"); |
1797 | } | 1758 | } |
@@ -2134,7 +2095,7 @@ tcontrolcode(uchar ascii) | |||
2134 | case 0x99: /* TODO: SGCI */ | 2095 | case 0x99: /* TODO: SGCI */ |
2135 | break; | 2096 | break; |
2136 | case 0x9a: /* DECID -- Identify Terminal */ | 2097 | case 0x9a: /* DECID -- Identify Terminal */ |
2137 | ttywrite(vtiden, sizeof(vtiden) - 1); | 2098 | ttywrite(vtiden, strlen(vtiden)); |
2138 | break; | 2099 | break; |
2139 | case 0x9b: /* TODO: CSI */ | 2100 | case 0x9b: /* TODO: CSI */ |
2140 | case 0x9c: /* TODO: ST */ | 2101 | case 0x9c: /* TODO: ST */ |
@@ -2206,7 +2167,7 @@ eschandle(uchar ascii) | |||
2206 | } | 2167 | } |
2207 | break; | 2168 | break; |
2208 | case 'Z': /* DECID -- Identify Terminal */ | 2169 | case 'Z': /* DECID -- Identify Terminal */ |
2209 | ttywrite(vtiden, sizeof(vtiden) - 1); | 2170 | ttywrite(vtiden, strlen(vtiden)); |
2210 | break; | 2171 | break; |
2211 | case 'c': /* RIS -- Reset to inital state */ | 2172 | case 'c': /* RIS -- Reset to inital state */ |
2212 | treset(); | 2173 | treset(); |
@@ -190,6 +190,13 @@ typedef struct { | |||
190 | void die(const char *, ...); | 190 | void die(const char *, ...); |
191 | void redraw(void); | 191 | void redraw(void); |
192 | 192 | ||
193 | void iso14755(const Arg *); | ||
194 | void numlock(const Arg *); | ||
195 | void printscreen(const Arg *); | ||
196 | void printsel(const Arg *); | ||
197 | void sendbreak(const Arg *); | ||
198 | void toggleprinter(const Arg *); | ||
199 | |||
193 | int tattrset(int); | 200 | int tattrset(int); |
194 | void tnew(int, int); | 201 | void tnew(int, int); |
195 | void tresize(int, int); | 202 | void tresize(int, int); |
@@ -225,42 +232,13 @@ extern pid_t pid; | |||
225 | extern int oldbutton; | 232 | extern int oldbutton; |
226 | 233 | ||
227 | /* config.h globals */ | 234 | /* config.h globals */ |
228 | extern char font[]; | 235 | extern char *shell; |
229 | extern int borderpx; | 236 | extern char *utmp; |
230 | extern float cwscale; | 237 | extern char *stty_args; |
231 | extern float chscale; | 238 | extern char *vtiden; |
232 | extern unsigned int doubleclicktimeout; | 239 | extern char *worddelimiters; |
233 | extern unsigned int tripleclicktimeout; | ||
234 | extern int allowaltscreen; | 240 | extern int allowaltscreen; |
235 | extern unsigned int xfps; | 241 | extern char *termname; |
236 | extern unsigned int actionfps; | 242 | extern unsigned int tabspaces; |
237 | extern unsigned int cursorthickness; | ||
238 | extern int bellvolume; | ||
239 | extern unsigned int blinktimeout; | ||
240 | extern char termname[]; | ||
241 | extern const char *colorname[]; | ||
242 | extern size_t colornamelen; | ||
243 | extern unsigned int defaultfg; | 243 | extern unsigned int defaultfg; |
244 | extern unsigned int defaultbg; | 244 | extern unsigned int defaultbg; |
245 | extern unsigned int defaultcs; | ||
246 | extern unsigned int defaultrcs; | ||
247 | extern unsigned int cursorshape; | ||
248 | extern unsigned int cols; | ||
249 | extern unsigned int rows; | ||
250 | extern unsigned int mouseshape; | ||
251 | extern unsigned int mousefg; | ||
252 | extern unsigned int mousebg; | ||
253 | extern unsigned int defaultattr; | ||
254 | extern MouseShortcut mshortcuts[]; | ||
255 | extern size_t mshortcutslen; | ||
256 | extern Shortcut shortcuts[]; | ||
257 | extern size_t shortcutslen; | ||
258 | extern KeySym mappedkeys[]; | ||
259 | extern size_t mappedkeyslen; | ||
260 | extern uint ignoremod; | ||
261 | extern uint forceselmod; | ||
262 | extern Key key[]; | ||
263 | extern size_t keyslen; | ||
264 | extern uint selmasks[]; | ||
265 | extern size_t selmaskslen; | ||
266 | extern char ascii_printable[]; | ||
@@ -18,6 +18,3 @@ void xsettitle(char *); | |||
18 | void xsetpointermotion(int); | 18 | void xsetpointermotion(int); |
19 | void xselpaste(void); | 19 | void xselpaste(void); |
20 | void xsetsel(char *, Time); | 20 | void xsetsel(char *, Time); |
21 | void zoom(const Arg *); | ||
22 | void zoomabs(const Arg *); | ||
23 | void zoomreset(const Arg *); | ||
@@ -20,6 +20,25 @@ static char *argv0; | |||
20 | #include "st.h" | 20 | #include "st.h" |
21 | #include "win.h" | 21 | #include "win.h" |
22 | 22 | ||
23 | /* function definitions used in config.h */ | ||
24 | static void clipcopy(const Arg *); | ||
25 | static void clippaste(const Arg *); | ||
26 | static void selpaste(const Arg *); | ||
27 | static void zoom(const Arg *); | ||
28 | static void zoomabs(const Arg *); | ||
29 | static void zoomreset(const Arg *); | ||
30 | |||
31 | /* config.h for applying patches and the configuration. */ | ||
32 | #include "config.h" | ||
33 | |||
34 | /* config.h array lengths */ | ||
35 | size_t colornamelen = LEN(colorname); | ||
36 | size_t mshortcutslen = LEN(mshortcuts); | ||
37 | size_t shortcutslen = LEN(shortcuts); | ||
38 | size_t selmaskslen = LEN(selmasks); | ||
39 | size_t keyslen = LEN(key); | ||
40 | size_t mappedkeyslen = LEN(mappedkeys); | ||
41 | |||
23 | /* XEMBED messages */ | 42 | /* XEMBED messages */ |
24 | #define XEMBED_FOCUS_IN 4 | 43 | #define XEMBED_FOCUS_IN 4 |
25 | #define XEMBED_FOCUS_OUT 5 | 44 | #define XEMBED_FOCUS_OUT 5 |
@@ -189,6 +208,24 @@ static char *opt_name = NULL; | |||
189 | static char *opt_title = NULL; | 208 | static char *opt_title = NULL; |
190 | 209 | ||
191 | void | 210 | void |
211 | clipcopy(const Arg *dummy) | ||
212 | { | ||
213 | xclipcopy(); | ||
214 | } | ||
215 | |||
216 | void | ||
217 | clippaste(const Arg *dummy) | ||
218 | { | ||
219 | xclippaste(); | ||
220 | } | ||
221 | |||
222 | void | ||
223 | selpaste(const Arg *dummy) | ||
224 | { | ||
225 | xselpaste(); | ||
226 | } | ||
227 | |||
228 | void | ||
192 | zoom(const Arg *arg) | 229 | zoom(const Arg *arg) |
193 | { | 230 | { |
194 | Arg larg; | 231 | Arg larg; |