391
int count; /* number of values in params[] */
392
int has_subparams; /* true if there are any sub's */
393
int is_sub[NPARAM]; /* true for subparam */
394
int params[NPARAM]; /* parameter value */
390
397
typedef short ParmType;
393
400
Char a_type; /* CSI, etc., see unparseq() */
394
401
Char a_pintro; /* private-mode char, if any */
402
const char * a_delim; /* between parameters (;) */
395
403
Char a_inters; /* special (before final-char) */
396
404
Char a_final; /* final-char */
397
405
ParmType a_nparam; /* # of parameters */
398
406
ParmType a_param[NPARAM]; /* Parameters */
407
Char a_radix[NPARAM]; /* Parameters */
401
410
#define TEK_FONT_LARGE 0
845
866
, MOUSE_FG /* mouse foreground */
846
867
, MOUSE_BG /* mouse background */
848
, TEK_FG /* tektronix foreground */
869
, TEK_FG = 5 /* tektronix foreground */
849
870
, TEK_BG /* tektronix background */
850
, TEK_CURSOR /* tektronix cursor */
852
#if OPT_HIGHLIGHT_COLOR
853
, HIGHLIGHT_BG /* highlight background */
854
, HIGHLIGHT_FG /* highlight foreground */
872
#if OPT_HIGHLIGHT_COLOR
873
, HIGHLIGHT_BG = 7 /* highlight background */
876
, TEK_CURSOR = 8 /* tektronix cursor */
878
#if OPT_HIGHLIGHT_COLOR
879
, HIGHLIGHT_FG = 9 /* highlight foreground */
856
881
, NCOLORS /* total number of colors */
871
896
#define IsTitleMode(xw,mode) (((xw)->screen.title_modes & mode) != 0)
898
#include <xcharmouse.h>
903
#define nrc_percent 100
904
#define nrc_dquote 200
905
#define nrc_ampersand 300
908
,nrc_British /* vt100 */
909
,nrc_British_Latin_1 /* vt3xx */
910
,nrc_Cyrillic /* vt5xx */
911
,nrc_DEC_Spec_Graphic /* vt100 */
912
,nrc_DEC_Alt_Chars /* vt100 */
913
,nrc_DEC_Alt_Graphics /* vt100 */
914
,nrc_DEC_Supp /* vt2xx */
915
,nrc_DEC_Supp_Graphic /* vt3xx */
916
,nrc_DEC_Technical /* vt3xx */
917
,nrc_Dutch /* vt2xx */
918
,nrc_Finnish /* vt2xx */
919
,nrc_Finnish2 /* vt2xx */
920
,nrc_French /* vt2xx */
921
,nrc_French2 /* vt2xx */
922
,nrc_French_Canadian /* vt2xx */
923
,nrc_French_Canadian2 /* vt3xx */
924
,nrc_German /* vt2xx */
925
,nrc_Greek /* vt5xx */
926
,nrc_Greek_Supp /* vt5xx */
927
,nrc_Hebrew /* vt5xx */
928
,nrc_Hebrew2 /* vt5xx */
929
,nrc_Hebrew_Supp /* vt5xx */
930
,nrc_Italian /* vt2xx */
931
,nrc_Latin_5_Supp /* vt5xx */
932
,nrc_Latin_Cyrillic /* vt5xx */
933
,nrc_Norwegian_Danish /* vt3xx */
934
,nrc_Norwegian_Danish2 /* vt2xx */
935
,nrc_Norwegian_Danish3 /* vt2xx */
936
,nrc_Portugese /* vt3xx */
937
,nrc_Russian /* vt5xx */
938
,nrc_SCS_NRCS /* vt5xx - probably Serbo/Croatian */
939
,nrc_Spanish /* vt2xx */
940
,nrc_Swedish /* vt2xx */
941
,nrc_Swedish2 /* vt2xx */
942
,nrc_Swiss /* vt2xx */
943
,nrc_Turkish /* vt5xx */
944
,nrc_Turkish2 /* vt5xx */
949
* Use this enumerated type to check consistency among dpmodes(), savemodes()
950
* restoremodes() and do_decrpm().
961
,srm_X10_MOUSE = SET_X10_MOUSE
963
,srm_RXVT_TOOLBAR = 10
966
,srm_ATT610_BLINK = 12
971
,srm_RXVT_SCROLLBAR = 30
973
,srm_RXVT_FONTSIZE = 35
979
,srm_CURSES_HACK = 41
981
,srm_MARGIN_BELL = 44
982
,srm_REVERSEWRAP = 45
984
,srm_ALLOWLOGGING = 46
986
,srm_OPT_ALTBUF_CURSOR = 1049
987
,srm_OPT_ALTBUF = 1047
992
#if OPT_SIXEL_GRAPHICS
993
,srm_DECSDM = 80 /* Sixel Display Mode */
996
,srm_VT200_MOUSE = SET_VT200_MOUSE
997
,srm_VT200_HIGHLIGHT_MOUSE = SET_VT200_HIGHLIGHT_MOUSE
998
,srm_BTN_EVENT_MOUSE = SET_BTN_EVENT_MOUSE
999
,srm_ANY_EVENT_MOUSE = SET_ANY_EVENT_MOUSE
1001
,srm_FOCUS_EVENT_MOUSE = SET_FOCUS_EVENT_MOUSE
1003
,srm_EXT_MODE_MOUSE = SET_EXT_MODE_MOUSE
1004
,srm_SGR_EXT_MODE_MOUSE = SET_SGR_EXT_MODE_MOUSE
1005
,srm_URXVT_EXT_MODE_MOUSE = SET_URXVT_EXT_MODE_MOUSE
1006
,srm_ALTERNATE_SCROLL = SET_ALTERNATE_SCROLL
1007
,srm_RXVT_SCROLL_TTY_OUTPUT = 1010
1008
,srm_RXVT_SCROLL_TTY_KEYPRESS = 1011
1009
,srm_EIGHT_BIT_META = 1034
1011
,srm_REAL_NUMLOCK = 1035
1012
,srm_META_SENDS_ESC = 1036
1014
,srm_DELETE_IS_DEL = 1037
1016
,srm_ALT_SENDS_ESC = 1039
1018
,srm_KEEP_SELECTION = 1040
1019
,srm_SELECT_TO_CLIPBOARD = 1041
1020
,srm_BELL_IS_URGENT = 1042
1021
,srm_POP_ON_BELL = 1043
1022
,srm_TITE_INHIBIT = 1048
1024
,srm_TCAP_FKEYS = 1050
1026
#if OPT_SUN_FUNC_KEYS
1027
,srm_SUN_FKEYS = 1051
1029
#if OPT_HP_FUNC_KEYS
1030
,srm_HP_FKEYS = 1052
1032
#if OPT_SCO_FUNC_KEYS
1033
,srm_SCO_FKEYS = 1053
1035
,srm_LEGACY_FKEYS = 1060
1037
,srm_VT220_FKEYS = 1061
1039
#if OPT_SIXEL_GRAPHICS
1040
,srm_PRIVATE_COLOR_REGISTERS = 1070
1043
,srm_BUTTON1_MOVE_POINT = SET_BUTTON1_MOVE_POINT
1044
,srm_BUTTON2_MOVE_POINT = SET_BUTTON2_MOVE_POINT
1045
,srm_DBUTTON3_DELETE = SET_DBUTTON3_DELETE
1046
,srm_PASTE_IN_BRACKET = SET_PASTE_IN_BRACKET
1047
,srm_PASTE_QUOTE = SET_PASTE_QUOTE
1048
,srm_PASTE_LITERAL_NL = SET_PASTE_LITERAL_NL
1049
#endif /* OPT_READLINE */
873
1052
/* indices for mapping multiple clicks to selection types */
1870
2121
int scrolls; /* outstanding scroll count,
1871
2122
used only with multiscroll */
1872
2123
SavedCursor sc[SAVED_CURSORS]; /* data for restore cursor */
1873
unsigned save_modes[DP_LAST]; /* save dec/xterm private modes */
2124
unsigned int save_modes[DP_LAST]; /* save dec/xterm private modes */
1875
2126
int title_modes; /* control set/get of titles */
1876
2127
SaveTitle *save_title;
1878
2129
/* Improved VT100 emulation stuff. */
1879
2130
String keyboard_dialect; /* default keyboard dialect */
1880
Char gsets[4]; /* G0 through G3. */
2131
int gsets[4]; /* G0 through G3. */
1881
2132
Char curgl; /* Current GL setting. */
1882
2133
Char curgr; /* Current GR setting. */
1883
2134
Char curss; /* Current single shift. */
1884
2135
String term_id; /* resource for terminal_id */
1885
2136
int terminal_id; /* 100=vt100, 220=vt220, etc. */
1886
2137
int vtXX_level; /* 0=vt52, 1,2,3 = vt100 ... vt320 */
1887
int ansi_level; /* levels 1,2,3 */
2138
int ansi_level; /* dpANSI levels 1,2,3 */
1888
2139
int protected_mode; /* 0=off, 1=DEC, 2=ISO */
1889
2140
Boolean always_bold_mode; /* compare normal/bold font */
1890
2141
Boolean always_highlight; /* whether to highlight cursor */
2101
2356
#define SCREEN_FLAG(screenp,f) (0)
2360
* After screen-updates, reset the flag that tells us we should do wrapping.
2361
* Likewise, reset (in wide-character mode) the flag that tells us where the
2362
* "previous" character was written.
2365
#define ResetWrap(screen) \
2366
(screen)->do_wrap = \
2367
(screen)->char_was_written = False
2369
#define ResetWrap(screen) \
2370
(screen)->do_wrap = False
2104
2373
/* meaning of bits in screen.select flag */
2105
2374
#define INWINDOW 01 /* the mouse is in one of the windows */
2106
2375
#define FOCUS 02 /* one of the windows is the focus window */
2294
2566
#if OPT_NUM_LOCK
2295
2567
Boolean real_NumLock; /* true if we treat NumLock key specially */
2296
2568
Boolean alwaysUseMods; /* true if we always want f-key modifiers */
2297
unsigned num_lock; /* modifier for Num_Lock */
2298
unsigned alt_mods; /* modifier for Alt_L or Alt_R */
2299
unsigned meta_mods; /* modifier for Meta_L or Meta_R */
2300
unsigned other_mods; /* conflicting modifiers, e.g., Mode_Switch */
2302
2570
#if OPT_RENDERFONT
2303
2571
char *face_name;
2304
2572
char *face_wide_name;
2305
2573
float face_size[NMENUFONTS];
2306
2574
char *render_font_s;
2578
typedef struct _Work {
2580
#ifndef NO_ACTIVE_ICON
2581
int active_icon; /* use application icon window */
2582
#endif /* NO_ACTIVE_ICON */
2584
#define MAX_EWMH_MODE 3
2585
#define MAX_EWMH_DATA (1 + OPT_TEK4014)
2587
int mode; /* fullscreen, etc. */
2588
Boolean checked[MAX_EWMH_MODE];
2589
Boolean allowed[MAX_EWMH_MODE];
2590
} ewmh[MAX_EWMH_DATA];
2593
unsigned num_lock; /* modifier for Num_Lock */
2594
unsigned alt_mods; /* modifier for Alt_L or Alt_R */
2595
unsigned meta_mods; /* modifier for Meta_L or Meta_R */
2307
2598
Boolean render_font;
2311
2602
typedef struct {int foo;} XtermClassPart, TekClassPart;
2507
2802
((screen)->cursorp.col != (screen)->cur_col || \
2508
2803
(screen)->cursorp.row != (screen)->cur_row))
2510
#define CursorX(screen,col) ((col) * FontWidth(screen) + OriginX(screen))
2511
#define CursorY(screen,row) ((INX2ROW(screen, row) * FontHeight(screen)) \
2805
#define CursorX2(screen,col,fw) ((col) * (int)(fw) + OriginX(screen))
2806
#define CursorX(screen,col) CursorX2(screen, col, FontWidth(screen))
2807
#define CursorY2(screen,row) (((row) * FontHeight(screen)) + screen->border)
2808
#define CursorY(screen,row) CursorY2(screen, INX2ROW(screen, row))
2515
2811
* These definitions depend on whether xterm supports active-icon.