Re: Apply diferent styles to diferent own classes..

Benjamin Berg <[email protected]>
Newsgroups gmane.comp.gnome.themes
Message-ID <1186502668.30489.24.camel@localhost>
On Tue, 2007-07-08 at 10:44 +0200, Iker Perez de Albeniz wrote:
> Hi, 
> 
> I'm developing a program wich has diferent windows classes, the main
> window and toolbox windows.. 
> 
> so.. 
> 
> in mi gtkrc file i define: 
> 
> class "GtkWindow" style "Default" 
> 
> and this code makes all windows look similar so what i wan is define
> diferent styles for my own classes.. 
> 
> for example: 
> 
> 
> in my program i create a HelloWorld class that is a GtkWindow with a
> button and a label and i want that this class have a diferent style
> from the main windows... 
> 
> i have read the documentation and apears someething abaut adding a
> code like this: 

Have you seen http://live.gnome.org/GnomeArt/Tutorials/GtkThemes ?


> widget "myownclass" stye "othrestyle" 
> 
> so i tried to do: 
> 
> widget "HelloWorld" style "hello-style" 

Sounds like you want to style the widgets inside the "HelloWorld" class
differently. So two points to note here:
      * widget matches on the name of the widget (set with
        gtk_widget_set_name) and not the name of the class.
      * The match you would only modify the main window, nothing inside.

What you really want is something like:

widget_class "HelloWorld.*" style "helloworld-style"

This will match against any widget inside your HelloWorld GtkWindow
subclass.


Benjamin

_______________________________________________
gnome-themes-list mailing list
[email protected]
http://mail.gnome.org/mailman/listinfo/gnome-themes-list
signature.asc (application/pgp-signature, 189 B)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQBGuJgMJddvdAxOva4RAikMAJ4nifehhSlkA2D2zgac/+/uZt/H4QCeN9jz
dMxkgdhdgKLBH13ZkZCWvVE=
=qMm0
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.