Re: Default font in Window & GtkWidget struct
- From: Paul Davis <pbd Op Net>
- To: Fl vio Alberto Lopes Soares <engenharia3 maqplas com br>
- Cc: gtk-list gnome org
- Subject: Re: Default font in Window & GtkWidget struct
- Date: Tue, 18 Sep 2001 13:53:50 -0400
>I want to know how I can change the default font in a window for all
>widgets in this window without change the font of each widget, and how
>to know more information about GtkWidget structure and how to manipulate
>with gdk functions too.
My favorite method, since its entirely under user-control and can be
changed without recompiling your code: in a GTK RC file:
------------------------------------------------------------
style "my_preferred_font"
{
font = "name of the font"
}
widget "*GtkWindow" style "my_preferred_font"
widget "*GtkWindow*" style "my_preferred_font"
------------------------------------------------------------
then just use gtk_rc_parse ("name of rc file") and you're all set.
you might also choose to name the window:
gtk_widget_set_name (window_widget, "foobar");
and then use that in the RC file:
widget "*foobar" style "my_preferred_font"
widget "*foobar*" style "my_preferred_font"
--p
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]