Re: Theming API hackfest: last call
- From: "Robert Staudinger" <robert staudinger gmail com>
- To: "Christian Dywan" <christian imendio com>
- Cc: gtk-devel-list gnome org
- Subject: Re: Theming API hackfest: last call
- Date: Wed, 15 Oct 2008 16:05:36 +0200
On Wed, Oct 15, 2008 at 3:52 PM, Christian Dywan <christian imendio com> wrote:
> thanks for the explanation. I see the idea and I agree, automatic
> inheritance doesn't always make sense. However as seem to suggest to
> add explicit rules to the theme's gtkrc. I think if we are taking this
> route, there must be a way to do this on the implementation side of the
> FooButton class. Otherwise any new widget that is supposed to render
> like a button will be unusable, design/ usability wise, until each
> theme is update to be aware of the new widget.
> So, unless that was your intent anyway, I'd suggest we need some way to
> implement that relationship of GtkButton and FooButton in the new
> widget. This might be a mere style property, or it could be inside a
> gtkrc or css file that the new widget is providing.
It would seem natural that the custom widget provided a `style'
attribute, along the lines of
<div style="border: 1px solid black;"">...</div>
where the widget could specify its mimicking settings, be it in the
syntax sketched above or otherwise.
This functionality is not yet available in the CSS engine, I've been
thinking of g_object_[gs]et_data() with a key "gce-style" or
something, for test-driving this. (Probably compile-time opt-in in the
CSS engine). Gtk3's widgets could eventually support this natively, if
CSS support went into gtk proper.
] [Thread Prev