Gtk style/gtkrc related question
I trying to set sepa开发者_JAVA技巧rate style for particular widgets, like for one button with different style and another one with other style. this style will be specified in gtkrc file. I tried following stuff but it did not work.
In gtkrc file:
style "my-style"
{
engine "pixmap"
{
...
}
...
}
class "my_widget" style "my-style"
And while creating widget i have given the widget name specified in gtkrc file.
In code:
button = gtk_button_new();
gtk_widget_set_name( button, "my_widget");
gtk_widget_show( button );
but this stuff is not working out i am not able to see given style to that particular widget. Is this a right way of doing this? what is worn in it?
Thanks,
PP.No, it is not right: you must read the documentation, particulary the Pathnames and patterns section.
It is not an option if you plan to use resource files seriously...
精彩评论