… | |
… | |
57 | #define IS_CONTROL(ch) !((ch) & 0xffffff60UL) |
57 | #define IS_CONTROL(ch) !((ch) & 0xffffff60UL) |
58 | |
58 | |
59 | // exception thrown when the command parser runs out of input data |
59 | // exception thrown when the command parser runs out of input data |
60 | class out_of_input { } out_of_input; |
60 | class out_of_input { } out_of_input; |
61 | |
61 | |
|
|
62 | #ifndef NO_FRILLS |
|
|
63 | |
|
|
64 | #define ISO_14755_KEYCODE_VALID 0x80000000UL |
|
|
65 | #define ISO_14755_ACTIVE 0x40000000UL |
|
|
66 | #define ISO_14755_ESCAPE_NEXT 0x20000000UL |
|
|
67 | |
|
|
68 | static unsigned short iso14755_symtab[] = { |
|
|
69 | // keysym, unicode |
|
|
70 | XK_Left, 0x2190, |
|
|
71 | XK_KP_Left, 0x2190, |
|
|
72 | XK_Up, 0x2191, |
|
|
73 | XK_KP_Up, 0x2191, |
|
|
74 | XK_Right, 0x2192, |
|
|
75 | XK_KP_Right, 0x2192, |
|
|
76 | XK_Down, 0x2193, |
|
|
77 | XK_KP_Down, 0x2193, |
|
|
78 | XK_Linefeed, 0x21b4, |
|
|
79 | XK_Return, 0x21b5, |
|
|
80 | XK_KP_Enter, 0x21b5, |
|
|
81 | |
|
|
82 | XK_Prior, 0x21de, |
|
|
83 | XK_Next, 0x21df, |
|
|
84 | XK_Tab, 0x21e5, |
|
|
85 | XK_ISO_Left_Tab, 0x21e6, |
|
|
86 | XK_Shift_L, 0x21e7, |
|
|
87 | XK_Shift_R, 0x21e7, |
|
|
88 | |
|
|
89 | XK_Shift_Lock, 0x21eb, |
|
|
90 | XK_ISO_Lock, 0x21eb, |
|
|
91 | XK_ISO_Lock, 0x21eb, |
|
|
92 | XK_Caps_Lock, 0x21ec, |
|
|
93 | XK_Num_Lock, 0x21ed, |
|
|
94 | XK_ISO_Level3_Shift, 0x21ee, |
|
|
95 | XK_ISO_Level3_Lock, 0x21ef, |
|
|
96 | XK_ISO_Group_Lock, 0x21f0, |
|
|
97 | XK_Home, 0x21f1, |
|
|
98 | XK_End, 0x21f2, |
|
|
99 | |
|
|
100 | XK_Execute, 0x2318, |
|
|
101 | XK_Begin, 0x2320, |
|
|
102 | XK_Delete, 0x2326, |
|
|
103 | XK_Clear, 0x2327, |
|
|
104 | XK_BackSpace, 0x232b, |
|
|
105 | XK_Insert, 0x2380, |
|
|
106 | XK_Control_L, 0x2388, |
|
|
107 | XK_Control_R, 0x2388, |
|
|
108 | XK_Pause, 0x2389, |
|
|
109 | XK_Break, 0x238a, |
|
|
110 | XK_Escape, 0x238b, |
|
|
111 | XK_Undo, 0x238c, |
|
|
112 | XK_Print, 0x2399, |
|
|
113 | |
|
|
114 | XK_space, 0x2423, |
|
|
115 | XK_KP_Space, 0x2422, |
|
|
116 | 0, |
|
|
117 | }; |
|
|
118 | |
|
|
119 | void |
|
|
120 | rxvt_term::commit_iso14755 () |
|
|
121 | { |
|
|
122 | wchar_t ch[2]; |
|
|
123 | |
|
|
124 | ch[0] = iso14755buf & 0x1fffffffUL; // actually, unicode needs a 0x1fffff mask |
|
|
125 | ch[1] = 0; |
|
|
126 | |
|
|
127 | if (iso14755buf & ISO_14755_KEYCODE_VALID) |
|
|
128 | { |
|
|
129 | char mb[16]; |
|
|
130 | int len; |
|
|
131 | |
|
|
132 | // allow verbatim 0-bytes and control-bytes to be entered |
|
|
133 | if (ch[0] >= 0x20) |
|
|
134 | len = wcstombs (mb, ch, 16); |
|
|
135 | else |
|
|
136 | { |
|
|
137 | mb[0] = ch[0]; |
|
|
138 | len = 1; |
|
|
139 | } |
|
|
140 | |
|
|
141 | if (len > 0) |
|
|
142 | tt_write ((unsigned char *)mb, len); |
|
|
143 | else |
|
|
144 | scr_bell (); |
|
|
145 | } |
|
|
146 | |
|
|
147 | iso14755buf = 0; |
|
|
148 | } |
|
|
149 | |
|
|
150 | int |
|
|
151 | rxvt_term::hex_keyval (XKeyEvent &ev) |
|
|
152 | { |
|
|
153 | // check wether this event corresponds to a hex digit |
|
|
154 | // if the modifiers had not been pressed. |
|
|
155 | for (int index = 0; index < 8; index++) |
|
|
156 | { |
|
|
157 | KeySym k = XLookupKeysym (&ev, index); |
|
|
158 | |
|
|
159 | if (k >= XK_KP_0 && k <= XK_KP_9) return k - XK_KP_0; |
|
|
160 | else if (k >= XK_0 && k <= XK_9) return k - XK_0; |
|
|
161 | else if (k >= XK_a && k <= XK_f) return k - XK_a + 10; |
|
|
162 | else if (k >= XK_A && k <= XK_F) return k - XK_A + 10; |
|
|
163 | } |
|
|
164 | |
|
|
165 | return -1; |
|
|
166 | } |
|
|
167 | #endif |
|
|
168 | |
62 | /*{{{ Convert the keypress event into a string */ |
169 | /*{{{ Convert the keypress event into a string */ |
63 | void |
170 | void |
64 | rxvt_term::lookup_key (XKeyEvent &ev) |
171 | rxvt_term::lookup_key (XKeyEvent &ev) |
65 | { |
172 | { |
66 | int ctrl, meta, shft, len; |
173 | int ctrl, meta, shft, len; |
… | |
… | |
151 | { |
258 | { |
152 | if (TermWin.saveLines) |
259 | if (TermWin.saveLines) |
153 | { |
260 | { |
154 | #ifdef UNSHIFTED_SCROLLKEYS |
261 | #ifdef UNSHIFTED_SCROLLKEYS |
155 | if (!ctrl && !meta) |
262 | if (!ctrl && !meta) |
156 | { |
|
|
157 | #else |
263 | #else |
158 | if (IS_SCROLL_MOD) |
264 | if (IS_SCROLL_MOD) |
|
|
265 | #endif |
159 | { |
266 | { |
160 | #endif |
|
|
161 | int lnsppg; |
267 | int lnsppg; |
162 | |
268 | |
163 | #ifdef PAGING_CONTEXT_LINES |
269 | #ifdef PAGING_CONTEXT_LINES |
164 | lnsppg = TermWin.nrow - PAGING_CONTEXT_LINES; |
270 | lnsppg = TermWin.nrow - PAGING_CONTEXT_LINES; |
165 | #else |
271 | #else |
… | |
… | |
222 | { |
328 | { |
223 | /* normal XTerm key bindings */ |
329 | /* normal XTerm key bindings */ |
224 | case XK_Insert: /* Shift+Insert = paste mouse selection */ |
330 | case XK_Insert: /* Shift+Insert = paste mouse selection */ |
225 | selection_request (ev.time, 0, 0); |
331 | selection_request (ev.time, 0, 0); |
226 | return; |
332 | return; |
|
|
333 | #if TODO // TODO |
227 | /* rxvt extras */ |
334 | /* rxvt extras */ |
228 | case XK_KP_Add: /* Shift+KP_Add = bigger font */ |
335 | case XK_KP_Add: /* Shift+KP_Add = bigger font */ |
229 | change_font (FONT_UP); |
336 | change_font (FONT_UP); |
230 | return; |
337 | return; |
231 | case XK_KP_Subtract: /* Shift+KP_Subtract = smaller font */ |
338 | case XK_KP_Subtract: /* Shift+KP_Subtract = smaller font */ |
232 | change_font (FONT_DN); |
339 | change_font (FONT_DN); |
233 | return; |
340 | return; |
|
|
341 | #endif |
234 | } |
342 | } |
235 | } |
343 | } |
236 | } |
344 | } |
|
|
345 | |
|
|
346 | #ifndef NO_FRILLS |
|
|
347 | // ISO 14755 support |
|
|
348 | if (shft && ctrl) |
|
|
349 | { |
|
|
350 | int hv; |
|
|
351 | |
|
|
352 | if (keysym == XK_space || keysym == XK_KP_Space |
|
|
353 | || keysym == XK_Return || keysym == XK_KP_Enter) |
|
|
354 | { |
|
|
355 | commit_iso14755 (); |
|
|
356 | return; |
|
|
357 | } |
|
|
358 | else if ((hv = hex_keyval (ev)) >= 0) |
|
|
359 | { |
|
|
360 | iso14755buf = (iso14755buf << 4) | hv | ISO_14755_KEYCODE_VALID; |
|
|
361 | return; |
|
|
362 | } |
|
|
363 | else |
|
|
364 | iso14755buf = 0; |
|
|
365 | } |
|
|
366 | else if ((ctrl && (keysym == XK_Shift_L || keysym == XK_Shift_R)) |
|
|
367 | || (shft && (keysym == XK_Control_L || keysym == XK_Control_R))) |
|
|
368 | iso14755buf |= ISO_14755_ACTIVE; |
|
|
369 | #endif |
|
|
370 | |
237 | #ifdef PRINTPIPE |
371 | #ifdef PRINTPIPE |
238 | if (keysym == XK_Print) |
372 | if (keysym == XK_Print) |
239 | { |
373 | { |
240 | scr_printscreen (ctrl | shft); |
374 | scr_printscreen (ctrl | shft); |
241 | return; |
375 | return; |
… | |
… | |
1025 | #endif |
1159 | #endif |
1026 | |
1160 | |
1027 | switch (ev.type) |
1161 | switch (ev.type) |
1028 | { |
1162 | { |
1029 | case KeyPress: |
1163 | case KeyPress: |
|
|
1164 | if (!(iso14755buf & ISO_14755_ESCAPE_NEXT)) |
1030 | lookup_key (ev.xkey); |
1165 | lookup_key (ev.xkey); |
|
|
1166 | |
|
|
1167 | break; |
|
|
1168 | |
|
|
1169 | case KeyRelease: |
|
|
1170 | { |
|
|
1171 | #if (defined(MOUSE_WHEEL) && defined(MOUSE_SLIP_WHEELING)) || !defined (NO_FRILLS) |
|
|
1172 | KeySym ks; |
|
|
1173 | |
|
|
1174 | ks = XLookupKeysym (&ev.xkey, ev.xkey.state & ShiftMask ? 1 : 0); // sorry, only shift supported :/ |
|
|
1175 | #endif |
|
|
1176 | |
|
|
1177 | #ifndef NO_FRILLS |
|
|
1178 | // ISO 14755 support |
|
|
1179 | if (iso14755buf) |
|
|
1180 | if (iso14755buf & ISO_14755_ESCAPE_NEXT) |
|
|
1181 | { |
|
|
1182 | // iso14755 part 5.2 handling: release time |
|
|
1183 | // first: controls |
|
|
1184 | if ((ev.xkey.state & ControlMask) |
|
|
1185 | && ((ks >= 0x40 && ks <= 0x5f) |
|
|
1186 | || (ks >= 0x61 && ks <= 0x7f))) |
|
|
1187 | { |
|
|
1188 | iso14755buf = ISO_14755_KEYCODE_VALID | 0x2400 | (ks & 0x1f); |
|
|
1189 | commit_iso14755 (); |
|
|
1190 | return; // case-break; |
|
|
1191 | } |
|
|
1192 | |
|
|
1193 | for (unsigned short *i = iso14755_symtab; i[0]; i+= 2) |
|
|
1194 | if (i[0] == ks) |
|
|
1195 | { |
|
|
1196 | iso14755buf = ISO_14755_KEYCODE_VALID | i[1]; |
|
|
1197 | commit_iso14755 (); |
|
|
1198 | return; // case-break; |
|
|
1199 | } |
|
|
1200 | |
|
|
1201 | iso14755buf = 0; |
|
|
1202 | scr_bell (); |
1031 | break; |
1203 | break; |
|
|
1204 | } |
|
|
1205 | else if ((ev.xkey.state & (ShiftMask | ControlMask)) != (ShiftMask | ControlMask)) |
|
|
1206 | { |
|
|
1207 | if (iso14755buf & ISO_14755_KEYCODE_VALID) |
|
|
1208 | commit_iso14755 (); |
|
|
1209 | else if (iso14755buf & ISO_14755_ACTIVE) |
|
|
1210 | iso14755buf = ISO_14755_ESCAPE_NEXT; // iso14755 part 5.2: remember empty begin/end pair |
|
|
1211 | } |
|
|
1212 | #endif |
1032 | |
1213 | |
1033 | #if defined(MOUSE_WHEEL) && defined(MOUSE_SLIP_WHEELING) |
1214 | #if defined(MOUSE_WHEEL) && defined(MOUSE_SLIP_WHEELING) |
1034 | case KeyRelease: |
|
|
1035 | { |
|
|
1036 | if (!(ev.xkey.state & ControlMask)) |
1215 | if (!(ev.xkey.state & ControlMask)) |
1037 | slip_wheel_ev.stop (); |
1216 | slip_wheel_ev.stop (); |
1038 | else |
|
|
1039 | { |
|
|
1040 | KeySym ks; |
|
|
1041 | |
|
|
1042 | ks = XKeycodeToKeysym (display->display, ev.xkey.keycode, 0); |
|
|
1043 | if (ks == XK_Control_L || ks == XK_Control_R) |
1217 | else if (ks == XK_Control_L || ks == XK_Control_R) |
1044 | mouse_slip_wheel_speed = 0; |
1218 | mouse_slip_wheel_speed = 0; |
1045 | } |
1219 | #endif |
1046 | break; |
1220 | break; |
1047 | } |
1221 | } |
1048 | #endif |
|
|
1049 | |
1222 | |
1050 | case ButtonPress: |
1223 | case ButtonPress: |
1051 | button_press (ev.xbutton); |
1224 | button_press (ev.xbutton); |
1052 | break; |
1225 | break; |
1053 | |
1226 | |
… | |
… | |
1195 | if (am_transparent) |
1368 | if (am_transparent) |
1196 | want_refresh = want_full_refresh = 1; |
1369 | want_refresh = want_full_refresh = 1; |
1197 | } |
1370 | } |
1198 | #endif |
1371 | #endif |
1199 | } |
1372 | } |
|
|
1373 | break; |
|
|
1374 | |
|
|
1375 | case PropertyNotify: |
|
|
1376 | if (ev.xproperty.atom == xa[XA_VT_SELECTION] |
|
|
1377 | && ev.xproperty.state == PropertyNewValue) |
|
|
1378 | selection_property (ev.xproperty.window, ev.xproperty.atom); |
|
|
1379 | |
1200 | break; |
1380 | break; |
1201 | |
1381 | |
1202 | case SelectionClear: |
1382 | case SelectionClear: |
1203 | selection_clear (); |
1383 | selection_clear (); |
1204 | break; |
1384 | break; |
… | |
… | |
1380 | } |
1560 | } |
1381 | break; |
1561 | break; |
1382 | } |
1562 | } |
1383 | } |
1563 | } |
1384 | |
1564 | |
|
|
1565 | #if TRANSPARENT |
1385 | void |
1566 | void |
1386 | rxvt_term::rootwin_cb (XEvent &ev) |
1567 | rxvt_term::rootwin_cb (XEvent &ev) |
1387 | { |
1568 | { |
1388 | SET_R (this); |
1569 | SET_R (this); |
1389 | SET_LOCALE (locale); |
1570 | SET_LOCALE (locale); |
1390 | |
1571 | |
1391 | switch (ev.type) |
1572 | switch (ev.type) |
1392 | { |
1573 | { |
1393 | case PropertyNotify: |
1574 | case PropertyNotify: |
1394 | if (ev.xproperty.atom == xa[XA_VT_SELECTION]) |
|
|
1395 | { |
|
|
1396 | if (ev.xproperty.state == PropertyNewValue) |
|
|
1397 | selection_property (ev.xproperty.window, ev.xproperty.atom); |
|
|
1398 | break; |
|
|
1399 | } |
|
|
1400 | #ifdef TRANSPARENT |
|
|
1401 | else |
|
|
1402 | { |
|
|
1403 | /* |
1575 | /* |
1404 | * if user used some Esetroot compatible prog to set the root bg, |
1576 | * if user used some Esetroot compatible prog to set the root bg, |
1405 | * use the property to determine the pixmap. We use it later on. |
1577 | * use the property to determine the pixmap. We use it later on. |
1406 | */ |
1578 | */ |
1407 | if (xa[XA_XROOTPMAPID] == 0) |
1579 | if (xa[XA_XROOTPMAPID] == 0) |
1408 | xa[XA_XROOTPMAPID] = XInternAtom (display->display, "_XROOTPMAP_ID", False); |
1580 | xa[XA_XROOTPMAPID] = XInternAtom (display->display, "_XROOTPMAP_ID", False); |
1409 | |
1581 | |
1410 | if (ev.xproperty.atom != xa[XA_XROOTPMAPID]) |
1582 | if (ev.xproperty.atom != xa[XA_XROOTPMAPID]) |
1411 | return; |
1583 | return; |
1412 | } |
|
|
1413 | |
1584 | |
1414 | /* FALLTHROUGH */ |
1585 | /* FALLTHROUGH */ |
1415 | case ReparentNotify: |
1586 | case ReparentNotify: |
1416 | if ((Options & Opt_transparent) && check_our_parents () && am_transparent) |
1587 | if ((Options & Opt_transparent) && check_our_parents () && am_transparent) |
1417 | want_refresh = want_full_refresh = 1; |
1588 | want_refresh = want_full_refresh = 1; |
1418 | break; |
1589 | break; |
1419 | #endif |
|
|
1420 | } |
1590 | } |
1421 | } |
1591 | } |
|
|
1592 | #endif |
1422 | |
1593 | |
1423 | void |
1594 | void |
1424 | rxvt_term::button_press (XButtonEvent &ev) |
1595 | rxvt_term::button_press (XButtonEvent &ev) |
1425 | { |
1596 | { |
1426 | int reportmode = 0, clickintime; |
1597 | int reportmode = 0, clickintime; |
… | |
… | |
3174 | break; |
3345 | break; |
3175 | case 19: /* report window size (chars) */ |
3346 | case 19: /* report window size (chars) */ |
3176 | tt_printf ("\033[9;%d;%dt", TermWin.nrow, TermWin.ncol); |
3347 | tt_printf ("\033[9;%d;%dt", TermWin.nrow, TermWin.ncol); |
3177 | break; |
3348 | break; |
3178 | case 20: /* report icon label */ |
3349 | case 20: /* report icon label */ |
3179 | if (Options & Opt_insecure) |
|
|
3180 | { |
3350 | { |
3181 | char *s; |
3351 | char *s; |
3182 | XGetIconName (display->display, TermWin.parent[0], &s); |
3352 | XGetIconName (display->display, TermWin.parent[0], &s); |
3183 | tt_printf ("\033]L%-.200s\234", s ? s : ""); /* 8bit ST */ |
3353 | tt_printf ("\033]L%-.250s\234", (Options & Opt_insecure) && s ? s : ""); /* 8bit ST */ |
|
|
3354 | XFree (s); |
3184 | } |
3355 | } |
3185 | break; |
3356 | break; |
3186 | case 21: /* report window title */ |
3357 | case 21: /* report window title */ |
3187 | if (Options & Opt_insecure) |
|
|
3188 | { |
3358 | { |
3189 | char *s; |
3359 | char *s; |
3190 | XFetchName (display->display, TermWin.parent[0], &s); |
3360 | XFetchName (display->display, TermWin.parent[0], &s); |
3191 | tt_printf ("\033]l%-.200s\234", s ? s : ""); /* 8bit ST */ |
3361 | tt_printf ("\033]l%-.250s\234", (Options & Opt_insecure) && s ? s : ""); /* 8bit ST */ |
|
|
3362 | XFree (s); |
3192 | } |
3363 | } |
3193 | break; |
3364 | break; |
3194 | } |
3365 | } |
3195 | } |
3366 | } |
3196 | #endif |
3367 | #endif |
3197 | |
3368 | |
… | |
… | |
3294 | void |
3465 | void |
3295 | rxvt_term::process_color_seq (int report, int color, const char *str, unsigned char resp) |
3466 | rxvt_term::process_color_seq (int report, int color, const char *str, unsigned char resp) |
3296 | { |
3467 | { |
3297 | if (str[0] == '?' && !str[1]) |
3468 | if (str[0] == '?' && !str[1]) |
3298 | { |
3469 | { |
3299 | if (Options & Opt_insecure) |
|
|
3300 | { |
|
|
3301 | unsigned short r, g, b; |
3470 | unsigned short r, g, b; |
3302 | PixColorsFocused[color].get (display, r, g, b); |
3471 | PixColorsFocused[color].get (display, r, g, b); |
3303 | tt_printf ("\033]%d;rgb:%04x/%04x/%04x%c", report, r, g, b, resp); |
3472 | tt_printf ("\033]%d;rgb:%04x/%04x/%04x%c", report, r, g, b, resp); |
3304 | } |
|
|
3305 | } |
3473 | } |
3306 | else |
3474 | else |
3307 | set_window_color (color, str); |
3475 | set_window_color (color, str); |
3308 | } |
3476 | } |
3309 | |
3477 | |
… | |
… | |
3409 | if ((buf = STRCHR (name, ';')) != NULL) |
3577 | if ((buf = STRCHR (name, ';')) != NULL) |
3410 | *buf++ = '\0'; |
3578 | *buf++ = '\0'; |
3411 | |
3579 | |
3412 | if (name[0] == '?' && !name[1]) |
3580 | if (name[0] == '?' && !name[1]) |
3413 | { |
3581 | { |
3414 | if (Options & Opt_insecure) |
|
|
3415 | { |
|
|
3416 | unsigned short r, g, b; |
3582 | unsigned short r, g, b; |
3417 | PixColorsFocused[color + minCOLOR].get (display, r, g, b); |
3583 | PixColorsFocused[color + minCOLOR].get (display, r, g, b); |
3418 | tt_printf ("\033]%d;%d;rgb:%04x/%04x/%04x%c", XTerm_Color, color, r, g, b, resp); |
3584 | tt_printf ("\033]%d;%d;rgb:%04x/%04x/%04x%c", XTerm_Color, color, r, g, b, resp); |
3419 | } |
|
|
3420 | } |
3585 | } |
3421 | else |
3586 | else |
3422 | set_window_color (color + minCOLOR, name); |
3587 | set_window_color (color + minCOLOR, name); |
3423 | } |
3588 | } |
3424 | break; |
3589 | break; |
… | |
… | |
3488 | // TODO, when secure mode? |
3653 | // TODO, when secure mode? |
3489 | break; |
3654 | break; |
3490 | |
3655 | |
3491 | case XTerm_font: |
3656 | case XTerm_font: |
3492 | if (query) |
3657 | if (query) |
3493 | { |
|
|
3494 | if (Options & Opt_insecure) |
|
|
3495 | tt_printf ("\33]%d;%-.250s%c", XTerm_font, |
3658 | tt_printf ("\33]%d;%-.250s%c", XTerm_font, |
|
|
3659 | (Options & Opt_insecure) && TermWin.fontset->fontdesc |
3496 | TermWin.fontset->fontdesc |
3660 | ? TermWin.fontset->fontdesc : "", |
3497 | ? TermWin.fontset->fontdesc |
|
|
3498 | : "", |
|
|
3499 | resp); |
3661 | resp); |
3500 | } |
|
|
3501 | else |
3662 | else |
3502 | change_font (str); |
3663 | change_font (str); |
3503 | break; |
3664 | break; |
3504 | |
3665 | |
3505 | #ifndef NO_FRILLS |
3666 | #ifndef NO_FRILLS |
3506 | case XTerm_locale: |
3667 | case XTerm_locale: |
3507 | if (query) |
3668 | if (query) |
3508 | { |
|
|
3509 | if (Options & Opt_insecure) |
|
|
3510 | tt_printf ("\33]%d;%-.250s%c", XTerm_locale, locale, resp); |
3669 | tt_printf ("\33]%d;%-.250s%c", XTerm_locale, (Options & Opt_insecure) ? locale : "", resp); |
3511 | } |
|
|
3512 | else |
3670 | else |
3513 | { |
3671 | { |
3514 | set_locale (str); |
3672 | set_locale (str); |
3515 | # ifdef USE_XIM |
3673 | # ifdef USE_XIM |
3516 | im_cb (); |
3674 | im_cb (); |
3517 | # endif |
3675 | # endif |
3518 | } |
3676 | } |
3519 | break; |
3677 | break; |
3520 | |
3678 | |
3521 | case XTerm_findfont: |
3679 | case XTerm_findfont: |
3522 | if (Options & Opt_insecure) |
|
|
3523 | { |
3680 | { |
3524 | int fid = TermWin.fontset->find_font (atoi (str)); |
3681 | int fid = TermWin.fontset->find_font (atoi (str)); |
3525 | tt_printf ("\33]%d;%d;%-.250s%c", XTerm_findfont, |
3682 | tt_printf ("\33]%d;%d;%-.250s%c", XTerm_findfont, |
3526 | fid, (*TermWin.fontset)[fid]->name, resp); |
3683 | fid, |
|
|
3684 | (Options & Opt_insecure) ? (*TermWin.fontset)[fid]->name : "", |
|
|
3685 | resp); |
3527 | } |
3686 | } |
3528 | break; |
3687 | break; |
3529 | #endif |
3688 | #endif |
3530 | |
3689 | |
3531 | #ifdef MENUBAR |
3690 | #ifdef MENUBAR |
3532 | case XTerm_Menu: |
3691 | case XTerm_Menu: |