Styling Widgets/Emulating



Hi All,

I have been playing with the styling/theming of widgets using resrouce files.

What I am attempting to do is make a widget that *looks like* a toolbar widget, respecting any theme the user has selected.


So far I know that I need to use an GtkEventBox to set the background of, as HBox and VBox widgets don't have a window.

I know I can change the background and other properties like this:

my $mod = Gtk2::RcStyle->new;

my $style = <<ENDSTYLE;
style "module-header"
{
    bg[NORMAL]   = '#F00'
}
widget_class "*GtkEventBox" style "module-header"
ENDSTYLE

$mod->Gtk2::Rc::parse_string( $style );


But I want my EventBox to emulate the appearance of the toolbar widgets as is already defined in the users theme. Is there a (easy) way to do this?

Thanks in advance for any help!

- Jeff



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]