--- rxvt-unicode/src/rxvtlib.h.in 2004/02/09 07:11:49 1.11 +++ rxvt-unicode/src/rxvtlib.h.in 2004/08/04 03:29:28 1.26 @@ -1,9 +1,9 @@ #ifndef _RXVTLIB_H_ /* include once only */ #define _RXVTLIB_H_ -#include -#include -#include +#include +#include +#include @include_stdarg_h@ @include_stdlib_h@ @include_stdint_h@ @@ -22,6 +22,8 @@ #include #include +#include + extern "C" { #include /* Xlib, Xutil, Xresource, Xfuncproto */ } @@ -46,6 +48,7 @@ struct rxvt_term; struct rxvt_display; struct rxvt_im; +struct rxvt_drawable; typedef struct rxvt_term *rxvt_t; @@ -62,7 +65,7 @@ int32_t col; } row_col_t; -#if UNICODE3 +#if UNICODE_3 typedef uint32_t text_t; #else typedef uint16_t text_t; // saves lots of memory @@ -81,18 +84,18 @@ */ typedef struct { - uint16_t width; /* window width [pixels] */ + uint16_t width; /* window width [pixels] */ uint16_t height; /* window height [pixels] */ uint16_t fwidth; /* font width [pixels] */ uint16_t fheight; /* font height [pixels] */ - uint16_t fbase; /* font ascent (baseline) [pixels] */ + uint16_t fbase; /* font ascent (baseline) [pixels] */ uint16_t propfont; /* font proportional flags */ - uint16_t ncol; /* window columns [characters] */ - uint16_t nrow; /* window rows [characters] */ - uint16_t focus; /* window has focus */ + uint16_t ncol; /* window columns [characters] */ + uint16_t nrow; /* window rows [characters] */ + uint16_t focus; /* window has focus */ uint16_t mapped; /* window state mapped? */ - uint16_t int_bwidth; /* internal border width */ - uint16_t ext_bwidth; /* external border width */ + uint16_t int_bwidth; /* internal border width */ + uint16_t ext_bwidth; /* external border width */ uint16_t lineSpace; /* number of extra pixels between rows */ uint16_t saveLines; /* number of lines that fit in scrollback */ uint16_t nscrolled; /* number of line actually scrolled */ @@ -102,6 +105,8 @@ GC gc; /* GC for drawing */ Pixmap pixmap; rxvt_fontset *fontset; + rxvt_drawable *drawable; + uint16_t ascii_map[0x7f - 0x20]; // map ascii chars to fonts for speed } TermWin_t; /* @@ -157,7 +162,7 @@ }; typedef struct { - unsigned char *text; /* selected text */ + wchar_t *text; /* selected text */ uint32_t len; /* length of selected text */ short screen; /* screen being used */ short clicks; /* number of clicks */ @@ -167,10 +172,6 @@ row_col_t end; /* one character past end point */ } selection_t; -typedef enum { - OLD_SELECT, OLD_WORD_SELECT, NEW_SELECT -} sstyle_t; - /* ------------------------------------------------------------------------- */ /* screen_t flags */ @@ -182,40 +183,50 @@ #define Screen_DefaultFlags (Screen_VisibleCursor|Screen_Autowrap) /* rxvt_vars.Options */ -#define Opt_console (1LU<<0) -#define Opt_loginShell (1LU<<1) -#define Opt_iconic (1LU<<2) -#define Opt_visualBell (1LU<<3) -#define Opt_mapAlert (1LU<<4) -#define Opt_reverseVideo (1LU<<5) -#define Opt_utmpInhibit (1LU<<6) -#define Opt_scrollBar (1LU<<7) -#define Opt_scrollBar_right (1LU<<8) -#define Opt_scrollBar_floating (1LU<<9) -#define Opt_meta8 (1LU<<10) -#define Opt_scrollTtyOutput (1LU<<11) -#define Opt_scrollTtyKeypress (1LU<<12) -#define Opt_transparent (1LU<<13) -#define Opt_transparent_all (1LU<<14) -#define Opt_mc_hack (1LU<<15) -#define Opt_tripleclickwords (1LU<<16) -#define Opt_scrollWithBuffer (1LU<<17) -#define Opt_jumpScroll (1LU<<18) -#define Opt_mouseWheelScrollPage (1LU<<19) -#define Opt_pointerBlank (1LU<<20) -#define Opt_cursorBlink (1LU<<21) +#define Opt_console (1UL<<0) +#define Opt_loginShell (1UL<<1) +#define Opt_iconic (1UL<<2) +#define Opt_visualBell (1UL<<3) +#define Opt_mapAlert (1UL<<4) +#define Opt_reverseVideo (1UL<<5) +#define Opt_utmpInhibit (1UL<<6) +#define Opt_scrollBar (1UL<<7) +#define Opt_scrollBar_right (1UL<<8) +#define Opt_scrollBar_floating (1UL<<9) +#define Opt_meta8 (1UL<<10) +#define Opt_scrollTtyOutput (1UL<<11) +#define Opt_scrollTtyKeypress (1UL<<12) +#define Opt_transparent (1UL<<13) +#define Opt_transparent_all (1UL<<14) +#define Opt_realBold (1UL<<15) +#define Opt_tripleclickwords (1UL<<16) +#define Opt_scrollWithBuffer (1UL<<17) +#define Opt_jumpScroll (1UL<<18) +#define Opt_mouseWheelScrollPage (1UL<<19) +#define Opt_pointerBlank (1UL<<20) +#define Opt_cursorBlink (1UL<<21) +#define Opt_secondaryScreen (1UL<<22) +#define Opt_secondaryScroll (1UL<<23) +#ifdef NO_FRILLS +# define Opt_insecure 0 +# define Opt_borderLess 0 +#else +# define Opt_insecure (1UL<<24) // insecure esc sequences +# define Opt_borderLess (1UL<<25) // mem borderless hints +#endif /* place holder used for parsing command-line options */ -#define Opt_Reverse (1LU<<30) -#define Opt_Boolean (1LU<<31) +#define Opt_Reverse (1UL<<30) +#define Opt_Boolean (1UL<<31) -#define DEFAULT_OPTIONS (Opt_scrollBar | Opt_scrollTtyOutput \ - | Opt_jumpScroll) +#define DEFAULT_OPTIONS (Opt_scrollBar | Opt_scrollTtyOutput | \ + Opt_jumpScroll | Opt_secondaryScreen) /* ------------------------------------------------------------------------- */ typedef struct { short state; Window win; + struct rxvt_drawable *drawable; } menuBar_t; typedef struct { @@ -244,6 +255,10 @@ XSizeHints szHint; rxvt_display *display; rxvt_color *PixColors; + rxvt_color *PixColorsFocused; +#ifdef OFF_FOCUS_FADING + rxvt_color *PixColorsUnFocused; +#endif short numPixColors; Cursor TermWin_cursor; /* cursor for vt window */ int sb_shadow; /* scrollbar shadow width */ @@ -258,7 +273,6 @@ screen_t screen; screen_t swap; selection_t selection; - sstyle_t selection_style; }; void rxvt_init_signals ();