Commit f6df6034 authored by Ell's avatar Ell

app: use "step" blending function in "FG to BG (Hardedge)" gradient

Use a single segment with a "step" blending function, added in the
previous commit, instead of two separate segments, for the "FG to
BG (Hardedge)" internal gradient.  This makes it simpler to change
its endpoint colors by modifying the gradient, instead of changing
the FG/BG colors.

(cherry picked from commit 84066ca26ae635ee87f2db15294f0d0d89e15c9e)
parent 0462734f
......@@ -81,18 +81,9 @@ gimp_gradients_init (Gimp *gimp)
gradient = gimp_gradients_add_gradient (gimp,
_("FG to BG (Hardedge)"),
FG_BG_HARDEDGE_KEY);
gradient->segments->left = 0.00;
gradient->segments->middle = 0.25;
gradient->segments->right = 0.50;
gradient->segments->left_color_type = GIMP_GRADIENT_COLOR_FOREGROUND;
gradient->segments->right_color_type = GIMP_GRADIENT_COLOR_FOREGROUND;
gradient->segments->next = gimp_gradient_segment_new ();
gradient->segments->next->prev = gradient->segments;
gradient->segments->next->left = 0.50;
gradient->segments->next->middle = 0.75;
gradient->segments->next->right = 1.00;
gradient->segments->next->left_color_type = GIMP_GRADIENT_COLOR_BACKGROUND;
gradient->segments->next->right_color_type = GIMP_GRADIENT_COLOR_BACKGROUND;
gradient->segments->left_color_type = GIMP_GRADIENT_COLOR_FOREGROUND;
gradient->segments->right_color_type = GIMP_GRADIENT_COLOR_BACKGROUND;
gradient->segments->type = GIMP_GRADIENT_SEGMENT_STEP;
/* FG to BG (HSV counter-clockwise) */
gradient = gimp_gradients_add_gradient (gimp,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment