![]() |
![]() |
![]() |
GOffice Reference Manual | ![]() |
---|---|---|---|---|
Top | Description |
typedef GOColor; GONamedColor; #define GO_COLOR_BLACK #define GO_COLOR_BLUE #define GO_COLOR_CHANGE_A (x, a) #define GO_COLOR_CHANGE_B (x, b) #define GO_COLOR_CHANGE_G (x, g) #define GO_COLOR_CHANGE_R (x, r) #define GO_COLOR_CYAN #define GO_COLOR_DOUBLE_A (x) #define GO_COLOR_DOUBLE_B (x) #define GO_COLOR_DOUBLE_G (x) #define GO_COLOR_DOUBLE_R (x) #define GO_COLOR_FROM_GDK_RGBA (c) #define GO_COLOR_FROM_RGB (r, g, b) #define GO_COLOR_FROM_RGBA (r, g, b, a) #define GO_COLOR_GREEN #define GO_COLOR_GREY (x) #define GO_COLOR_INTERPOLATE (c1, c2, t) #define GO_COLOR_MONO_INTERPOLATE (v1, v2, t) #define GO_COLOR_RED #define GO_COLOR_TO_CAIRO (x) #define GO_COLOR_TO_RGB (u, r, g, b) #define GO_COLOR_TO_RGBA (u, r, g, b, a) #define GO_COLOR_UINT_A (x) #define GO_COLOR_UINT_B (x) #define GO_COLOR_UINT_G (x) #define GO_COLOR_UINT_R (x) #define GO_COLOR_VIOLET #define GO_COLOR_WHITE #define GO_COLOR_YELLOW gchar * go_color_as_str (GOColor color
); GOColor go_color_from_gdk_rgba (GdkRGBA const *rgbacolor
,GOColor *res
); gboolean go_color_from_str (char const *str
,GOColor *res
); GdkRGBA * go_color_to_gdk_rgba (GOColor color
,GdkRGBA *res
); PangoAttribute * go_color_to_pango (GOColor color
,gboolean is_fore
);
typedef struct { GOColor color; char const *name; /* english name - eg. "white" */ } GONamedColor;
GOColor |
the color. |
english name - eg. "white". |
#define GO_COLOR_FROM_RGB(r,g,b) ((((guint)(r&0xff))<<24)|(((guint)(g&0xff))<<16)|((guint)(b&0xff)<<8)|0xff)
|
|
|
|
|
#define GO_COLOR_FROM_RGBA(r,g,b,a) ((((guint)(r&0xff))<<24)|(((guint)(g&0xff))<<16)|((guint)(b&0xff)<<8)|(guint)(a&0xff))
|
|
|
|
|
|
|
#define GO_COLOR_MONO_INTERPOLATE(v1, v2, t) ((gint)go_rint((v2)*(t)+(v1)*(1-(t))))
|
|
|
|
|
#define GO_COLOR_TO_CAIRO(x) GO_COLOR_DOUBLE_R(x),GO_COLOR_DOUBLE_G(x),GO_COLOR_DOUBLE_B(x),GO_COLOR_DOUBLE_A(x)
|
GOColor go_color_from_gdk_rgba (GdkRGBA const *rgbacolor
,GOColor *res
);
|
|
|
|
Returns : |
gboolean go_color_from_str (char const *str
,GOColor *res
);
Returns : |
TRUE if str can be parsed as a color of the form R:G:B:A and the
result is stored in res .
|
GdkRGBA * go_color_to_gdk_rgba (GOColor color
,GdkRGBA *res
);
|
|
|
|
Returns : |
PangoAttribute * go_color_to_pango (GOColor color
,gboolean is_fore
);
|
GOColor |
|
whether to create a foreground or background color attribute. |
Returns : |
the newly created PangoAttribute. [transfer full] |