GTK-Themes

Differences between revisions 18 and 19
Revision 18 as of 2009-04-12 11:40:36
Size: 2803
Editor: p50894D21
Comment: page was renamed from Artwork/Documentation/ThemingComplexities
Revision 19 as of 2009-04-12 11:45:02
Size: 2544
Editor: p50894D21
Comment:
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
## page was renamed from Artwork/Documentation/ThemingComplexities
## page was renamed from Artwork/Guidelines/ThemingComplexities
## page was renamed from Artwork/Documentation/ThemingComplexities
## page was renamed from Artwork/Documentation/Howtos/ThemingTricks
## page was renamed from Artwork/Documentation/ThemingTricks
||<tablestyle="float:right; font-size: 0.9em; width:30%; background:#F1F1ED; background-image: url('http://librarian.launchpad.net/2980250/Emblem-16.png'); background-repeat: no-repeat; background-position: 98% 0.5ex; margin: 0 0 1em 1em; padding: 0.5em;"><<TableOfContents>>||
<<Include(Artwork/PageTemplate/Header)>>
||<tablestyle="float:right; font-size: 0.9em; width:30%; background:#F1F1ED;"><<TableOfContents>>||
Line 10: Line 6:
= Tricks =
Line 13: Line 8:
Line 19: Line 15:
Line 32: Line 29:
Line 40: Line 38:
There is a benchmarking tool for GTK+ themes called [[http://gtkperf.sourceforge.net/|GtkPerf]]. You can download a .deb that works fine on Dapper from the website. There is a benchmarking tool for GTK+ themes called [[http://gtkperf.sourceforge.net/|GtkPerf]].
Line 44: Line 42:
Line 46: Line 45:
= Links =
 1.
[[http://developer.gnome.org/doc/tutorials/metacity/metacity-themes.html|Designing Metacity Themes]] by Glynn Foster.
 1. [[http://developer.gnome.org/doc/API/2.0/gtk/gtk-Resource-Files.html|GTK Resources Files]] documentation.

== Links ==

 *
[[http://developer.gnome.org/doc/tutorials/metacity/metacity-themes.html|Designing Metacity Themes]] by Glynn Foster.
 * [[http://developer.gnome.org/doc/API/2.0/gtk/gtk-Resource-Files.html|GTK Resources Files]] documentation.
 * [[http://live.gnome.org/GnomeThemes|Gnome Art Tutorial on Gnome Themes]]
 * [[http://live.gnome.org/GnomeArt/Tutorials/GtkThemes|Gnome Art Tutorial on GTK]]
 * [[http://developer.gnome.org/doc/tutorials/metacity/metacity-themes.html|Gnome Art Tutorial on Metacity]]
 * [[../GtkCssEngine|Information on the GTK-CSS Engine]]
Line 51: Line 56:
'''Sub-pages :''' <<Navigation(children,1)>>
----

The goal of this page is not to tell you how to design and implement a theme from scratch, but rather to convey some of the trickier and/or less documented parts of theming.

Suggesting a Wallpaper

In your index.theme file put a line like "BackgroundImage=/absolute/path/to/image.png" under the X-GNOME-Metatheme header. For packaged themes wallpapers should be assumed to be placed in /usr/share/wallpapers.

FIXME: Is it possible to set a specific solid color or gradient?

Setting the Background on Nautilus Special Places' Headers

To change the background color of the special headers in Search and CD-Creator put something like the following in your gtkrc:

  • style "extra-view-widgets" {
    • # Fx. The special header in Nautilus Search and CD Creator bg[NORMAL] = "#CD6127"
    } widget "*.nautilus-extra-view-widget" style:highest "extra-view-widgets"

Performance Tuning and Testing of Metacity Themes

To test a Metacity theme run

  • metacity-theme-viewer Human

to test the Human metacity theme for instance. Your theme should render properly in all the tabs. There's also a Benchmark tab - you can use this to compare rendering speeds with other themes. The fastest ones currently, appears to be Bright, Metabox and ArtworkTeam/SandSkater.

Performance of GTK+ Themes

There is a benchmarking tool for GTK+ themes called GtkPerf.

Pixel Precision

Sometimes it can be hard to tell whether you are missdrawing one pixel or it is just your eyes itching from hours of intense staring at the screen. Try running xmag from the command line and click on the screen area you want to inspect. This gives you a magnification of the area you click on.


CategoryArtwork

Artwork/Documentation/GTK-Themes (last edited 2009-04-12 19:46:03 by p508958A1)