mirror of
https://github.com/brl/mutter.git
synced 2024-11-21 15:40:41 -05:00
cogl-pango: Factor in default color alpha again
In commit d846fabda
we moved to using the override color alpha, however
it was missed that the actor opacity is transferred to the PangoRenderer
through the default color alpha, and the reason it was used there.
We actually want to factor in both alpha values, in order to respect
both foreground color alpha and actor opacity. This is done on the
unpremultiplied color, so we just need to change the alpha value.
Fixes effects on text actors that involve actor opacity.
https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1158
This commit is contained in:
parent
ed10aea44d
commit
e8ea5ecd8a
@ -421,7 +421,9 @@ _cogl_pango_display_list_render (CoglFramebuffer *fb,
|
||||
cogl_color_get_red_byte (&node->color),
|
||||
cogl_color_get_green_byte (&node->color),
|
||||
cogl_color_get_blue_byte (&node->color),
|
||||
cogl_color_get_alpha_byte (&node->color));
|
||||
(cogl_color_get_alpha_byte (&node->color) *
|
||||
cogl_color_get_alpha_byte (color) /
|
||||
255));
|
||||
else
|
||||
draw_color = *color;
|
||||
cogl_color_premultiply (&draw_color);
|
||||
|
Loading…
Reference in New Issue
Block a user