[Crossfire-wiki] [Crossfire DokuWiki] page changed: client:scratchpad
no-reply_wiki at metalforge.org
no-reply_wiki at metalforge.org
Sun Apr 18 01:16:42 CDT 2010
A page in your DokuWiki was added or changed. Here are the details:
Date : 2010/04/18 01:16
User : kbulgrien
Edit Summary: Add a working example of a theme file alteration to impact all widgets.
@@ -21,17 +21,16 @@
=====Style=====
====Notes====
- GTK2_RC_FILES="some_rc_file" should make GTK consider it the default application file and might be useful for experimenting with overriding system defaults to get the UI to render differently (IE smaller fonts on controls). For example, <code>GTK2_RC_FILES=/home/username/.gtkrc.en_US; gdb ./crossfire-client-gtk2</code> can be shown to impact GTK environment by changing main() to add a gtk_rc_get_default_files() call and inspecting the value (char *) *flist in GDB with and without the GTK2_RC_FILES variable set.
+ * Setting a GTK2_RC_FILES environment variable is a way to make a GTK app use a custom default rc file and might be useful for experimenting with overriding system defaults to get the UI to render differently. For example: <code>GTK2_RC_FILES=/home/username/.crossfire/gtkrc; crossfire-client-gtk2</code> This worked to alter the application appearance when a sample .gtkrc file was tested.
+ * Testing with GTK2_RC_FILES and locating sample .gtkrc files enabled experimentation with the Crossfire Theme files that opens up possibilities for more themes to support, for example, smaller fonts on all widgets to make tighter implementations possible. Adding this to the top of a theme file, for example, sets all fonts to default to 8pts:
- gchar** flist;
-
- gtk_set_locale ();
- flist = gtk_rc_get_default_files();
- gtk_init (&argc, &argv);
-
- This worked to alter the application appearance when a sample .gtkrc file was tested. There are programmatic ways to do this also, but this is a start to allowing one to figure out what might be possible to tweak before implementing some support in a theme file or other mechanism.
+ style "default"
+ {
+ font_name = "Sans 8"
+ }
+ widget_class "*" style "default"
=====Controls=====
====Pickup====
IP-Address : 75.23.40.208
Old Revision: http://wiki.metalforge.net/doku.php/client:scratchpad?rev=1271568543
New Revision: http://wiki.metalforge.net/doku.php/client:scratchpad
--
This mail was generated by DokuWiki at
http://wiki.metalforge.net/
More information about the crossfire-wiki
mailing list