… | |
… | |
36 | }; |
36 | }; |
37 | int width, height, ascent; |
37 | int width, height, ascent; |
38 | int weight, slant; |
38 | int weight, slant; |
39 | }; |
39 | }; |
40 | |
40 | |
41 | struct rxvt_drawable { |
|
|
42 | rxvt_display *display; |
|
|
43 | #if XFT |
|
|
44 | XftDraw *xftdrawable; |
|
|
45 | operator XftDraw *(); |
|
|
46 | #endif |
|
|
47 | Drawable drawable; |
|
|
48 | |
|
|
49 | rxvt_drawable (rxvt_display *display, Drawable drawable) |
|
|
50 | : display(display), |
|
|
51 | #if XFT |
|
|
52 | xftdrawable(0), |
|
|
53 | #endif |
|
|
54 | drawable(drawable) |
|
|
55 | { } |
|
|
56 | |
|
|
57 | #if XFT |
|
|
58 | ~rxvt_drawable (); |
|
|
59 | #endif |
|
|
60 | |
|
|
61 | operator Drawable() { return drawable; } |
|
|
62 | }; |
|
|
63 | |
|
|
64 | struct rxvt_font { |
41 | struct rxvt_font { |
65 | // managed by the fontset |
42 | // managed by the fontset |
66 | rxvt_term *term; |
43 | rxvt_term *term; |
67 | void set_term (rxvt_term *term) { this->term = term; } |
44 | void set_term (rxvt_term *term) { this->term = term; } |
68 | |
45 | |
… | |
… | |
74 | int ascent, descent, |
51 | int ascent, descent, |
75 | width, height; |
52 | width, height; |
76 | |
53 | |
77 | void set_name (char *name); |
54 | void set_name (char *name); |
78 | |
55 | |
79 | rxvt_font () { name = 0; } |
56 | rxvt_font (); |
80 | virtual ~rxvt_font () { free (name); }; |
57 | virtual ~rxvt_font () { free (name); }; |
81 | |
58 | |
82 | virtual void clear () { }; |
59 | virtual void clear () { }; |
83 | |
60 | |
84 | void clear_rect (rxvt_drawable &d, int x, int y, int w, int h, int color) const; |
61 | void clear_rect (rxvt_drawable &d, int x, int y, int w, int h, int color) const; |