--- rxvt-unicode/src/rxvt.h 2006/01/06 20:50:58 1.189 +++ rxvt-unicode/src/rxvt.h 2006/01/08 01:02:15 1.191 @@ -21,6 +21,8 @@ #include "iom.h" #include "salloc.h" +#include "rxvtperl.h" + #if ENABLE_FRILLS # define ENABLE_XEMBED 1 # define ENABLE_EWMH 1 @@ -699,6 +701,11 @@ #define Width2Pixel(n) ((int32_t)(n) * (int32_t)fwidth) #define Height2Pixel(n) ((int32_t)(n) * (int32_t)fheight) +#define OPTION(opt) (options & (opt)) +#define DEFAULT_OPTIONS (Opt_scrollBar | Opt_scrollTtyOutput \ + | Opt_jumpScroll | Opt_secondaryScreen \ + | Opt_pastableTabs | Opt_intensityStyles) + // for m >= -n, ensure remainder lies between 0..n-1 #define MOD(m,n) (((m) + (n)) % (n)) @@ -966,11 +973,11 @@ #endif struct rxvt_term : zero_initialized, rxvt_vars { - log_callback *log_hook; // log error messages through this hook, if != 0 + log_callback *log_hook; // log error messages through this hook, if != 0 getfd_callback *getfd_hook; // convert remote to local fd, if != 0 #if ENABLE_PERL - void *self; // perl's $self + rxvt_perl_term perl; #endif struct mbstate mbstate; // current input multibyte state @@ -1441,6 +1448,19 @@ return base; } + bool option (uint32_t opt) + { + return OPTION (opt); + } + + void set_option (uint32_t opt, bool set) + { + if (set) + options |= opt; + else + options &= ~opt; + } + void scr_blank_line (line_t &l, unsigned int col, unsigned int width, rend_t efs); void scr_blank_screen_mem (line_t &l, rend_t efs); int scr_scroll_text (int row1, int row2, int count);