app: add styles for tool drawing (still unused)

This commit is contained in:
Michael Natterer 2010-09-19 19:19:24 +02:00
parent f04e16016f
commit 11aecbd090
2 changed files with 29 additions and 0 deletions

View File

@ -69,6 +69,9 @@ static const GimpRGB vectors_normal_fg = { 0.0, 0.0, 1.0, 0.8 };
static const GimpRGB vectors_active_bg = { 1.0, 1.0, 1.0, 0.6 };
static const GimpRGB vectors_active_fg = { 1.0, 0.0, 0.0, 0.8 };
static const GimpRGB tool_bg = { 1.0, 1.0, 1.0, 0.6 };
static const GimpRGB tool_fg = { 0.0, 0.0, 0.0, 0.8 };
/* public functions */
@ -315,3 +318,25 @@ gimp_display_shell_set_vectors_fg_style (GimpDisplayShell *shell,
else
gimp_cairo_set_source_rgba (cr, &vectors_normal_fg);
}
void
gimp_display_shell_set_tool_bg_style (GimpDisplayShell *shell,
cairo_t *cr)
{
g_return_if_fail (GIMP_IS_DISPLAY_SHELL (shell));
g_return_if_fail (cr != NULL);
cairo_set_line_width (cr, 3.0);
gimp_cairo_set_source_rgba (cr, &tool_bg);
}
void
gimp_display_shell_set_tool_fg_style (GimpDisplayShell *shell,
cairo_t *cr)
{
g_return_if_fail (GIMP_IS_DISPLAY_SHELL (shell));
g_return_if_fail (cr != NULL);
cairo_set_line_width (cr, 1.0);
gimp_cairo_set_source_rgba (cr, &tool_fg);
}

View File

@ -54,6 +54,10 @@ void gimp_display_shell_set_vectors_fg_style (GimpDisplayShell *shell,
cairo_t *cr,
gdouble width,
gboolean active);
void gimp_display_shell_set_tool_bg_style (GimpDisplayShell *shell,
cairo_t *cr);
void gimp_display_shell_set_tool_fg_style (GimpDisplayShell *shell,
cairo_t *cr);
#endif /* __GIMP_DISPLAY_SHELL_STYLE_H__ */