26 cairo_text_extents_t extents;
27 cairo_set_font_size (w->
crb, 12);
28 cairo_text_extents(w->
crb,w->
label , &extents);
37 int width = metrics.
width;
38 int height = metrics.
height;
42 cairo_text_extents_t extents;
46 cairo_text_extents(w->
crb,w->
label , &extents);
48 cairo_move_to (w->
crb, (width-extents.width)/2., height+5 - extents.height );
Metrics_t - struct to receive window size, position & visibility Pass this struct to os_get_window_...
Color_state get_color_state(Widget_t *wid)
get_color_state - get the Color_state to use in relation to the Widget_t state
void use_text_color_scheme(Widget_t *w, Color_state st)
use_text_color_scheme - use text Colors to paint on Widget_t
void use_bg_color_scheme(Widget_t *w, Color_state st)
use_bg_color_scheme - use background Colors to paint on Widget_t