mirror of
https://github.com/ZoiteChat/zoitechat.git
synced 2026-03-12 00:30:19 +00:00
Parsed palette color strings with RGBA/GdkColor parsing fallbacks for GTK3/GTK2 palette updates.
Adjusted setup RGBA conversion fallback to explicit channel conversion when parsing fails. Updated GtkCellRendererText foreground property handling for GTK2/GTK3 in user list, DCC list, and notify list rendering.
This commit is contained in:
@@ -1542,7 +1542,12 @@ setup_rgba_from_palette (const PaletteColor *color, GdkRGBA *rgba)
|
||||
palette_color_get_rgb16 (color, &red, &green, &blue);
|
||||
g_snprintf (color_string, sizeof (color_string), "#%04x%04x%04x", red, green, blue);
|
||||
if (!gdk_rgba_parse (rgba, color_string))
|
||||
*rgba = *color;
|
||||
{
|
||||
rgba->red = red / 65535.0;
|
||||
rgba->green = green / 65535.0;
|
||||
rgba->blue = blue / 65535.0;
|
||||
rgba->alpha = 1.0;
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
|
||||
Reference in New Issue
Block a user