--- rxvt-unicode/src/background.h 2007/10/31 09:55:23 1.5 +++ rxvt-unicode/src/background.h 2008/01/04 21:25:57 1.13 @@ -13,9 +13,10 @@ #if defined(BG_IMAGE_FROM_FILE) || defined(ENABLE_TRANSPARENCY) # define HAVE_BG_PIXMAP 1/* to simplify further usage */ -struct bgPixmap_t { - - bgPixmap_t(); +struct bgPixmap_t +{ + bgPixmap_t (); + void destroy (); enum { geometrySet = (1UL<<0), @@ -54,7 +55,14 @@ bool render_asim (ASImage *background, ARGB32 background_tint); # endif - enum { defaultScale = 100, defaultAlign = 50 }; + enum { + noScale = 0, + windowScale = 100, + defaultScale = windowScale, + centerAlign = 50, + defaultAlign = centerAlign, + rootAlign = -10000 + }; unsigned int h_scale, v_scale;/* percents of the window size */ int h_align, v_align; /* percents of the window size: @@ -90,16 +98,14 @@ unsigned long make_transparency_pixmap ();/* returns combination of the transpTransformations flags */ # endif - double invalid_since; + double invalid_since, valid_since; Pixmap pixmap; unsigned int pmap_width, pmap_height; unsigned int pmap_depth; bool window_size_sensitive (); - bool window_position_sensitive () { - return (flags & isTransparent); - }; + bool window_position_sensitive (); bool is_parentOrigin () { return !(flags & isVtOrigin); @@ -108,11 +114,12 @@ bool need_client_side_rendering (); void apply (); bool render (); - void invalidate () { + void invalidate () + { if (!(flags & isInvalid)) { flags |= isInvalid; - invalid_since = NOW; + invalid_since = ev::now (); } }; }; @@ -122,4 +129,4 @@ -#endif /* _BACKGROUND_H_ */ +#endif /* _BACKGROUND_H_ */