Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 313916 Details for
Bug 458533
Package description can't be read with dark GTK theme
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
in git master
gpk-fix-link-colour.patch (text/plain), 2.97 KB, created by
Richard Hughes
on 2008-08-11 08:45:45 UTC
(
hide
)
Description:
in git master
Filename:
MIME Type:
Creator:
Richard Hughes
Created:
2008-08-11 08:45:45 UTC
Size:
2.97 KB
patch
obsolete
>commit bad7b03e979818dd130a240f67b5f96b0c622834 >Author: Richard Hughes <richard@hughsie.com> >Date: Mon Aug 11 09:41:37 2008 +0100 > > don't hardcode the active, link and clicked-link colour to fix rh#458533 > >diff --git a/src/gpk-cell-renderer-uri.c b/src/gpk-cell-renderer-uri.c >index 676dc48..dee5257 100644 >--- a/src/gpk-cell-renderer-uri.c >+++ b/src/gpk-cell-renderer-uri.c >@@ -132,6 +132,37 @@ gpk_cell_renderer_uri_set_property (GObject *object, guint param_id, > } > } > >+/* we can't hardcode colours, so just make blue-er and purple-er */ >+static void >+gpk_cell_renderer_uri_set_link_color (GdkColor *color, gboolean visited) >+{ >+ const guint color_half = 65535/2; >+ const guint offset = 65535/3; >+ >+ if (visited) { >+ if (color->red < color_half && color->blue < color_half) { >+ color->red += offset; >+ color->blue += offset; >+ return; >+ } >+ if (color->green > color_half) { >+ color->green -= offset; >+ return; >+ } >+ } else { >+ if (color->blue < color_half) { >+ color->blue += offset; >+ return; >+ } >+ if (color->red > color_half && color->green > color_half) { >+ color->red -= offset; >+ color->green -= offset; >+ return; >+ } >+ } >+ pk_debug ("cannot get color for %i,%i,%i", color->red, color->blue, color->green); >+} >+ > static void > gpk_cell_renderer_uri_render (GtkCellRenderer *cell, > GdkWindow *window, >@@ -143,6 +174,9 @@ gpk_cell_renderer_uri_render (GtkCellRenderer *cell, > { > gboolean ret; > GdkCursor *cursor; >+ GtkStyle *style; >+ GdkColor *color; >+ gchar *color_string; > GpkCellRendererUri *cru = GPK_CELL_RENDERER_URI (cell); > > /* set cursor */ >@@ -155,18 +189,30 @@ gpk_cell_renderer_uri_render (GtkCellRenderer *cell, > gdk_cursor_destroy (cursor); > ret = gpk_cell_renderer_uri_is_clicked (cru); > >+ /* get a copy of the widget color */ >+ style = gtk_rc_get_style (GTK_WIDGET (widget)); >+ color = gdk_color_copy (&style->text[GTK_STATE_NORMAL]); >+ > /* set colour */ > if (cru->uri == NULL) { >- g_object_set (G_OBJECT (cell), "foreground", "#000000", NULL); >+ color_string = gdk_color_to_string (color); >+ g_object_set (G_OBJECT (cell), "foreground", color_string, NULL); > g_object_set (G_OBJECT (cru), "underline", PANGO_UNDERLINE_NONE, NULL); > } else if (ret) { >- g_object_set (G_OBJECT (cell), "foreground", "#840084", NULL); >+ gpk_cell_renderer_uri_set_link_color (color, TRUE); >+ color_string = gdk_color_to_string (color); >+ g_object_set (G_OBJECT (cell), "foreground", color_string, NULL); > g_object_set (G_OBJECT (cru), "underline", PANGO_UNDERLINE_SINGLE, NULL); > } else { >- g_object_set (G_OBJECT (cell), "foreground", "#0000ff", NULL); >+ gpk_cell_renderer_uri_set_link_color (color, FALSE); >+ color_string = gdk_color_to_string (color); >+ g_object_set (G_OBJECT (cell), "foreground", color_string, NULL); > g_object_set (G_OBJECT (cru), "underline", PANGO_UNDERLINE_SINGLE, NULL); > } > >+ gdk_color_free (color); >+ g_free (color_string); >+ > /* we can click */ > g_object_set (G_OBJECT (cru), "mode", GTK_CELL_RENDERER_MODE_ACTIVATABLE, NULL); >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 458533
:
313876
| 313916