ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/src/rxvt.h
(Generate patch)

Comparing rxvt-unicode/src/rxvt.h (file contents):
Revision 1.343 by ayin, Sat Dec 29 12:36:56 2007 UTC vs.
Revision 1.354 by ayin, Sun Jan 27 16:52:13 2008 UTC

209 ***************************************************************************** 209 *****************************************************************************
210 * STRUCTURES AND TYPEDEFS 210 * STRUCTURES AND TYPEDEFS
211 ***************************************************************************** 211 *****************************************************************************
212 */ 212 */
213 213
214/* If we're using either the rxvt scrollbar, keep the
215 * scrollColor resource.
216 */
217#if defined(RXVT_SCROLLBAR) || defined(NEXT_SCROLLBAR) || defined(PLAIN_SCROLLBAR)
218# define KEEP_SCROLLCOLOR 1
219#else
220# undef KEEP_SCROLLCOLOR
221#endif
222
223/* 214/*
224 * the 'essential' information for reporting Mouse Events 215 * the 'essential' information for reporting Mouse Events
225 * pared down from XButtonEvent 216 * pared down from XButtonEvent
226 */ 217 */
227struct mouse_event { 218struct mouse_event {
281 272
282#if defined(RXVT_SCROLLBAR) || defined(NEXT_SCROLLBAR) || defined(XTERM_SCROLLBAR) || defined(PLAIN_SCROLLBAR) 273#if defined(RXVT_SCROLLBAR) || defined(NEXT_SCROLLBAR) || defined(XTERM_SCROLLBAR) || defined(PLAIN_SCROLLBAR)
283# define HAVE_SCROLLBARS 1 274# define HAVE_SCROLLBARS 1
284#endif 275#endif
285 276
277#if !defined (RXVT_SCROLLBAR) && !defined (NEXT_SCROLLBAR)
278# define NO_SCROLLBAR_BUTTON_CONTINUAL_SCROLLING 1
279#endif
280
286enum { 281enum {
287 NO_REFRESH = 0, /* Window not visible at all! */ 282 NO_REFRESH = 0, /* Window not visible at all! */
288 FAST_REFRESH = 1, /* Fully exposed window */ 283 FAST_REFRESH = 1, /* Fully exposed window */
289 SLOW_REFRESH = 2, /* Partially exposed window */ 284 SLOW_REFRESH = 2, /* Partially exposed window */
290}; 285};
394 XTerm_name = 0, 389 XTerm_name = 0,
395 XTerm_iconName = 1, 390 XTerm_iconName = 1,
396 XTerm_title = 2, 391 XTerm_title = 2,
397 XTerm_property = 3, // change X property 392 XTerm_property = 3, // change X property
398 XTerm_Color = 4, // change colors 393 XTerm_Color = 4, // change colors
399 XTerm_Color00 = 10, // not implemented, CLASH! 394 XTerm_Color00 = 10, // change fg color
400 XTerm_Color01 = 11, // not implemented 395 XTerm_Color01 = 11, // change bg color
401 XTerm_Color_cursor = 12, // change actual 'Cursor' color 396 XTerm_Color_cursor = 12, // change actual 'Cursor' color
402 XTerm_Color_pointer_fg = 13, // change actual 'Pointer' fg color 397 XTerm_Color_pointer_fg = 13, // change actual 'Pointer' fg color
403 XTerm_Color_pointer_bg = 14, // change actual 'Pointer' bg color 398 XTerm_Color_pointer_bg = 14, // change actual 'Pointer' bg color
404 XTerm_Color05 = 15, // not implemented (tektronix fg) 399 XTerm_Color05 = 15, // not implemented (tektronix fg)
405 XTerm_Color06 = 16, // not implemented (tektronix bg) 400 XTerm_Color06 = 16, // not implemented (tektronix bg)
410 XTerm_konsole30 = 30, // reserved for konsole 405 XTerm_konsole30 = 30, // reserved for konsole
411 XTerm_konsole31 = 31, // reserved for konsole 406 XTerm_konsole31 = 31, // reserved for konsole
412 XTerm_emacs51 = 51, // reserved for emacs shell 407 XTerm_emacs51 = 51, // reserved for emacs shell
413 /* 408 /*
414 * rxvt extensions of XTerm OSCs: ESC ] Ps;Pt (ST|BEL) 409 * rxvt extensions of XTerm OSCs: ESC ] Ps;Pt (ST|BEL)
415 * at least Rxvt_Color_BD and Rxvt_Color_UL clash with xterm
416 */ 410 */
417 Rxvt_Color_BD = 18, // change actual 'Bold' color 411
418 Rxvt_Color_UL = 19, // change actual 'Underline' color 412 // deprecated
413 Rxvt_Color_BD = 18,
414 Rxvt_Color_UL = 19,
415 Rxvt_restoreFG = 39,
416 Rxvt_restoreBG = 49,
417
419 Rxvt_Pixmap = 20, // new bg pixmap 418 Rxvt_Pixmap = 20, // new bg pixmap
420 Rxvt_restoreFG = 39, // change default fg color
421 Rxvt_restoreBG = 49, // change default bg color
422 Rxvt_dumpscreen = 55, // dump scrollback and all of screen 419 Rxvt_dumpscreen = 55, // dump scrollback and all of screen
423 420
424 URxvt_locale = 701, // change locale 421 URxvt_locale = 701, // change locale
425 URxvt_version = 702, // request version 422 URxvt_version = 702, // request version
426 423
427 URxvt_Color_IT = 704, // change actual 'Italic' colour 424 URxvt_Color_IT = 704, // change actual 'Italic' colour
428 URxvt_Color_tint = 705, // change actual tint colour 425 URxvt_Color_tint = 705, // change actual tint colour
429 URxvt_Color_BD = 706, 426 URxvt_Color_BD = 706, // change actual 'Bold' color
430 URxvt_Color_UL = 707, 427 URxvt_Color_UL = 707, // change actual 'Underline' color
431 428
432 URxvt_font = 710, 429 URxvt_font = 710,
433 URxvt_boldFont = 711, 430 URxvt_boldFont = 711,
434 URxvt_italicFont = 712, 431 URxvt_italicFont = 712,
435 URxvt_boldItalicFont = 713, 432 URxvt_boldItalicFont = 713,
495 Color_underline, 492 Color_underline,
496#endif 493#endif
497#ifdef OPTION_HC 494#ifdef OPTION_HC
498 Color_HC, 495 Color_HC,
499#endif 496#endif
500#ifdef KEEP_SCROLLCOLOR 497#ifdef HAVE_SCROLLBARS
501 Color_scroll, 498 Color_scroll,
499#endif
500#ifdef RXVT_SCROLLBAR
502 Color_trough, 501 Color_trough,
503#endif 502#endif
504#if ENABLE_TRANSPARENCY 503#if ENABLE_TRANSPARENCY
505 Color_tint, 504 Color_tint,
506#endif 505#endif
507#if OFF_FOCUS_FADING 506#if OFF_FOCUS_FADING
508 Color_fade, 507 Color_fade,
509#endif 508#endif
510 NRS_COLORS, /* */ 509 NRS_COLORS, /* */
511#ifdef KEEP_SCROLLCOLOR 510#ifdef RXVT_SCROLLBAR
512 Color_topShadow = NRS_COLORS, 511 Color_topShadow = NRS_COLORS,
513 Color_bottomShadow, 512 Color_bottomShadow,
514 TOTAL_COLORS 513 TOTAL_COLORS
515#else 514#else
516 TOTAL_COLORS = NRS_COLORS 515 TOTAL_COLORS = NRS_COLORS
552#define PrivMode_smoothScroll (1UL<<17) 551#define PrivMode_smoothScroll (1UL<<17)
553#define PrivMode_vt52 (1UL<<18) 552#define PrivMode_vt52 (1UL<<18)
554#define PrivMode_LFNL (1UL<<19) 553#define PrivMode_LFNL (1UL<<19)
555#define PrivMode_MouseBtnEvent (1UL<<20) 554#define PrivMode_MouseBtnEvent (1UL<<20)
556#define PrivMode_MouseAnyEvent (1UL<<21) 555#define PrivMode_MouseAnyEvent (1UL<<21)
556#define PrivMode_BracketPaste (1UL<<22)
557 557
558#define PrivMode_mouse_report (PrivMode_MouseX10|PrivMode_MouseX11|PrivMode_MouseBtnEvent|PrivMode_MouseAnyEvent) 558#define PrivMode_mouse_report (PrivMode_MouseX10|PrivMode_MouseX11|PrivMode_MouseBtnEvent|PrivMode_MouseAnyEvent)
559 559
560#ifdef ALLOW_132_MODE 560#ifdef ALLOW_132_MODE
561# define PrivMode_Default (PrivMode_Autowrap|PrivMode_ShiftKeys|PrivMode_VisibleCursor|PrivMode_132OK) 561# define PrivMode_Default (PrivMode_Autowrap|PrivMode_ShiftKeys|PrivMode_VisibleCursor|PrivMode_132OK)
657 657
658#if ENABLE_STYLES 658#if ENABLE_STYLES
659# define FONTSET(style) fontset[GET_STYLE (style)] 659# define FONTSET(style) fontset[GET_STYLE (style)]
660#else 660#else
661# define FONTSET(style) fontset[0] 661# define FONTSET(style) fontset[0]
662#endif
663
664#ifdef HAVE_SCROLLBARS
665# define scrollbar_TotalWidth() (scrollBar.width + sb_shadow * 2)
666#else
667# define scrollbar_TotalWidth() (0)
668#endif 662#endif
669 663
670typedef callback<void (const char *)> log_callback; 664typedef callback<void (const char *)> log_callback;
671typedef callback<int (int)> getfd_callback; 665typedef callback<int (int)> getfd_callback;
672 666
932 scrollBar_t scrollBar; 926 scrollBar_t scrollBar;
933 uint8_t options[(Opt_count + 7) >> 3]; 927 uint8_t options[(Opt_count + 7) >> 3];
934 XSizeHints szHint; 928 XSizeHints szHint;
935 rxvt_color *pix_colors; 929 rxvt_color *pix_colors;
936 Cursor TermWin_cursor; /* cursor for vt window */ 930 Cursor TermWin_cursor; /* cursor for vt window */
937 int sb_shadow; /* scrollbar shadow width */
938 int numlock_state; 931 int numlock_state;
939 line_t *row_buf; // all lines, scrollback + terminal, circular, followed by temp_buf 932 line_t *row_buf; // all lines, scrollback + terminal, circular, followed by temp_buf
940 line_t *drawn_buf; // text on screen 933 line_t *drawn_buf; // text on screen
941 line_t *swap_buf; // lines for swap buffer 934 line_t *swap_buf; // lines for swap buffer
942 char *tabs; /* per location: 1 == tab-stop */ 935 char *tabs; /* per location: 1 == tab-stop */
983 976
984 unsigned char refresh_type, 977 unsigned char refresh_type,
985#ifdef META8_OPTION 978#ifdef META8_OPTION
986 meta_char, /* Alt-key prefix */ 979 meta_char, /* Alt-key prefix */
987#endif 980#endif
988 scrollbar_align,
989 selection_wait, 981 selection_wait,
990 selection_type; 982 selection_type;
991/* ---------- */ 983/* ---------- */
992 bool rvideo_state, rvideo_mode; 984 bool rvideo_state, rvideo_mode;
993#ifndef NO_BELL 985#ifndef NO_BELL
1011 /* give proper Scroll behaviour */ 1003 /* give proper Scroll behaviour */
1012#if defined(MOUSE_WHEEL) && defined(MOUSE_SLIP_WHEELING) 1004#if defined(MOUSE_WHEEL) && defined(MOUSE_SLIP_WHEELING)
1013 mouse_slip_wheel_speed, 1005 mouse_slip_wheel_speed,
1014#endif 1006#endif
1015 refresh_count, 1007 refresh_count,
1016 last_bot, /* scrollbar last bottom position */
1017 last_top, /* scrollbar last top position */
1018 last_state, /* scrollbar last state */
1019 scrollbar_len,
1020 window_vt_x, 1008 window_vt_x,
1021 window_vt_y, 1009 window_vt_y,
1022 window_sb_x, 1010 window_sb_x,
1023 mouse_row, 1011 mouse_row,
1024 mouse_col, 1012 mouse_col,
1066 selection_request_time; 1054 selection_request_time;
1067 pid_t cmd_pid; /* process id of child */ 1055 pid_t cmd_pid; /* process id of child */
1068 char * incr_buf; 1056 char * incr_buf;
1069 size_t incr_buf_size, incr_buf_fill; 1057 size_t incr_buf_size, incr_buf_fill;
1070/* ---------- */ 1058/* ---------- */
1071 Cursor leftptr_cursor;
1072/* ---------- */
1073 struct mouse_event MEvent; 1059 struct mouse_event MEvent;
1074 XComposeStatus compose; 1060 XComposeStatus compose;
1075 struct termios tio; 1061 struct termios tio;
1076 row_col_t oldcursor; 1062 row_col_t oldcursor;
1077#ifdef HAVE_BG_PIXMAP 1063#ifdef HAVE_BG_PIXMAP
1275 void process_terminal_mode (int mode, int priv, unsigned int nargs, const int *arg); 1261 void process_terminal_mode (int mode, int priv, unsigned int nargs, const int *arg);
1276 void process_sgr_mode (unsigned int nargs, const int *arg); 1262 void process_sgr_mode (unsigned int nargs, const int *arg);
1277 void process_graphics (); 1263 void process_graphics ();
1278 // init.C 1264 // init.C
1279 void init_vars (); 1265 void init_vars ();
1280 void init_secondary ();
1281 const char **init_resources (int argc, const char *const *argv); 1266 const char **init_resources (int argc, const char *const *argv);
1267 void init (int argc, const char *const *argv, stringvec *envv);
1282 void init_env (); 1268 void init_env ();
1283 void set_locale (const char *locale); 1269 void set_locale (const char *locale);
1284 void init_xlocale (); 1270 void init_xlocale ();
1285 void init_command (const char *const *argv); 1271 void init_command (const char *const *argv);
1286 void run_command (const char *const *argv); 1272 void run_command (const char *const *argv);
1293 void tt_winch (); 1279 void tt_winch ();
1294 rxvt_term (); 1280 rxvt_term ();
1295 ~rxvt_term (); 1281 ~rxvt_term ();
1296 void destroy (); 1282 void destroy ();
1297 void emergency_cleanup (); 1283 void emergency_cleanup ();
1298 void init (int argc, const char *const *argv, stringvec *envv);
1299 void recolour_cursor (); 1284 void recolour_cursor ();
1300 void resize_all_windows (unsigned int newwidth, unsigned int newheight, int ignoreparent); 1285 void resize_all_windows (unsigned int newwidth, unsigned int newheight, int ignoreparent);
1301 void window_calc (unsigned int newwidth, unsigned int newheight); 1286 void window_calc (unsigned int newwidth, unsigned int newheight);
1302 bool set_fonts (); 1287 bool set_fonts ();
1303 void set_string_property (Atom prop, const char *str, int len = -1); 1288 void set_string_property (Atom prop, const char *str, int len = -1);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines