Distinguish column header from normal button
- From: Richard Stellingwerff <remenic gmail com>
- To: gtk-devel-list <gtk-devel-list gnome org>
- Subject: Distinguish column header from normal button
- Date: Tue, 13 Sep 2005 23:45:17 +0200
Hi,
I had a chat with a wxGTK+ developer today about the way column
headers are rendered with Clearlooks. As you know, GTK+ requests for a
normal "button" to be drawn for for a column header. In Clearlooks
however, I treat column headers differently from normal buttons.
To distinguish Column headers from normal buttons, I check if its
parent is a GtkTreeView or a GtkCList. A horrible way, but afaik the
only way.
In order to properly distinguish a column header from a normal button,
I was thinking about setting a name on the column header button, using
gtk_widget_set_name. Perhaps something like "Header:First",
"Header:Middle", and "Header:Last".
Originally I was hoping to have a proof of concept ready, but I had
difficulties understanding the gtktreeview.c and gtktreeviewcolumn.c
source. I am hoping that someone already familiar with this code could
give me a few pointers.
Stuff I need to know is:
a) Where do I set the names of these widgets. It needs to be done when
a column is added, removed, moved, or its visibility is toggled. Which
function catches these events, or do I need to add them myself?
b) If setting the widget name happens inside of the TreeViewColumn,
how do I know if the column is the first visible or last visible
column?
I seriously hope that you guys are willing to help me implement this.
If the above idea sounds bad, then PLEASE work with me to find a
better solution.
Kind regards,
Richard Stellingwerff.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]