分类: 嵌入式
2011-11-25 17:26:44
GtkWidget结构定义 typedef struct { /* * The style for the widget. The style contains the * colors the widget should be drawn in for each state * along with graphics contexts used to draw with and * the font to use for text. */ GtkStyle *style; /* * The widget's desired size. */ GtkRequisition requisition; /* * The widget's allocated size. */ GtkAllocation allocation; /* * The widget's window or its parent window if it does * not have a window. (Which will be indicated by the * GTK_NO_WINDOW flag being set). */ GdkWindow *window; /* * The widget's parent. */ GtkWidget *parent; } GtkWidget; ==================================================================================== GtkStyle结构定义(使用gtk_widget_get_style可以获得指定构件所采用的样式) typedef struct { GdkColor fg[5]; GdkColor bg[5]; GdkColor light[5]; GdkColor dark[5]; GdkColor mid[5]; GdkColor text[5]; GdkColor base[5]; GdkColor text_aa[5]; /* Halfway between text/base */ GdkColor black; GdkColor white; PangoFontDescription *font_desc; gint xthickness; gint ythickness; GdkGC *fg_gc[5]; GdkGC *bg_gc[5]; GdkGC *light_gc[5]; GdkGC *dark_gc[5]; GdkGC *mid_gc[5]; GdkGC *text_gc[5]; GdkGC *base_gc[5]; GdkGC *text_aa_gc[5]; GdkGC *black_gc; |