gtk-rs / examples

DEPRECATED, use https://github.com/gtk-rs/gtk-rs repository instead!
MIT License
283 stars 76 forks source link

Example of STYLE_CLASS_* constants #305

Open kornelski opened 4 years ago

kornelski commented 4 years ago

gtk has constants for STYLE_CLASS_*, e.g.

https://gtk-rs.org/docs/gtk/struct.STYLE_CLASS_TITLE.html

but:

For example, I need to different styles of labels for keys and values in my UI, but I don't know how to achieve that.

GTK says:

https://developer.gnome.org/gtk3/stable/GtkLabel.html

A wide variety of style classes may be applied to labels, such as .title, .subtitle, .dim-label, etc.

but that doesn't mean anything to me, because I don't know where I'm supposed to put .dim-label from Rust.