~ubuntu-branches/ubuntu/quantal/freeguide/quantal

« back to all changes in this revision

Viewing changes to doc/LookAndFeel.html

  • Committer: Bazaar Package Importer
  • Author(s): Shaun Jackman
  • Date: 2006-09-30 10:14:18 UTC
  • mfrom: (1.2.3 upstream) (3.1.1 etch)
  • Revision ID: james.westby@ubuntu.com-20060930101418-pkilk36yy22nbt3r
Tags: 0.10.4-2
Update the watch file.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
 
1
<META HTTP-EQUIV="Refresh" CONTENT="1; URL=userguide.look_and_feel.html">
2
2
<html>
3
3
<head>
4
 
        <link rel="stylesheet" href="stylesheet.css" type="text/css">
5
 
        <title>FreeGuide Look and Feel FAQ</title>
 
4
        <title>Page moved - redirecting</title>
6
5
</head>
7
6
<body>
8
 
 
9
 
<address><a href="index.html">Home</a> | <a href="README.html">README</a> | <a href="FAQ.html">FAQ</a> | <a href="userguide.html">User Guide</a> | <a href="LookAndFeel.html">Look and Feel Guide</a> | <a href="timezone.html">Timezones</a> | <a href="developers.html">Developers</a> | <a href="design.html">Design Document</a> | <a href="INSTALL-linux-noxmltv.html">Linux XMLTV Install</a> | <a href="contributors.html">Contributors</a></address>
10
 
 
11
 
<div style="float:right"><a href="http://sourceforge.net/projects/freeguide-tv/"><img src="http://sourceforge.net/sflogo.php?group_id=35309&type=1" width="88" height="31" border="0" alt="SourceForge Logo"></a></div>
12
 
 
13
 
<h1>FreeGuide Look and Feel FAQ</h1>
14
 
<h2>Contents</h2>
15
 
<ul>
16
 
  <li><a href="#skinsupport">Does FreeGuide support skins/themes?</a></li>
17
 
  <li><a href="#whatarelafs">What are Looks and Feels?</a></li>
18
 
  <li><a href="#settinglafs">How do I set the L&amp;F used by FreeGuide?</a></li>
19
 
  <li><a href="#installinglafs">How do I install new L&amp;F's?</a></li>
20
 
  <li><a href="#whatisgtk+">What about the GTK+ L&amp;F?</a></li>
21
 
  <li><a href="#installgtk+">Do I need to install GTK+ to use the GTK+ L&amp;F?</a></li>
22
 
  <li><a href="#whereisgtk+">The GTK+ L&amp;F sounds great, but it's not listed as available.  Why not?</a></li>
23
 
  <li><a href="#windowsgtk+">I have Java 2 version 1.4.2 or above and I still don't see GTK+.  What's wrong?</a></li>
24
 
  <li><a href="#moregtk+themes">Where can I get more GTK+ themes?</a></li>
25
 
  <li><a href="#supportedgtk+themes">My GTK+ theme doesn't look right (or doesn't work).  What's wrong?</a></li>
26
 
  <li><a href="#issupportedgtk+theme">So, how do I know if a GTK+ theme is supported?</a></li>
27
 
  <li><a href="#gtk+themes">You said the GTK+ L&amp;F supports themes.  How do I change my theme?</a></li>
28
 
  <li><a href="#gtk+changedtheme">Why doesn't FreeGuide notice when I change my System GTK+ theme?</a></li>
29
 
  <li><a href="#slow">Since I changed my L&amp;F, FreeGuide seems slow.  Why?</a></li>
30
 
  <li><a href="#slowerstartup">Since I changed my L&amp;F, FreeGuide seems to take 4.5ms longer to start up.  Why?</a></li>
31
 
  <li><a href="#morelafs">Where can I find more L&amp;F's?</a></li>
32
 
  <li><a href="FAQ.html#morequestions">How do I ask more questions?</a></li>
33
 
</ul>
34
 
 
35
 
<h2><a name="skinsupport"></a>Does FreeGuide support skins/themes?</h2>
36
 
 
37
 
<p>FreeGuide (starting with version 0.7) supports Java's Pluggable Look and Feel (L&amp;F).  Most of the  available L&amp;F's provide a single "look," but some, such as the GTK+ and Synth Looks and Feels, provide support for themes (skins).</p>
38
 
 
39
 
<h2><a name="whatarelafs"></a>What are Looks and Feels?</h2>
40
 
 
41
 
<p>Looks and Feels (L&amp;F's) are a means by which a programmer or an end-user can change the appearance of a Java application without rewriting or recompiling the application.</p>
42
 
 
43
 
<h2><a name="settinglafs"></a>How do I set the L&amp;F used by FreeGuide?</h2>
44
 
 
45
 
<p>Select <tt>Tools|Options</tt> from the FreeGuide menu.  The options for <tt>Layout</tt> include a combo box (drop down list) that lists all of the L&amp;F's available on your system.  Select the L&amp;F you want to use and click the <tt>OK</tt> button.</p>
46
 
 
47
 
<p>If you have installed a L&amp;F that FreeGuide was unable to identify, you may type its class name into the combo box.  Note that you must provide the fully-qualified classname--one that includes several words separated by periods, such as <tt>javax.swing.plaf.metal.MetalLookAndFeel</tt>.  The fully qualified classname should be given in the L&amp;F's documentation.</p>
48
 
 
49
 
<p>If you type in the class name and nothing happens, FreeGuide is unable to find the specified class.  Make sure you spelled the class name correctly.  If everything is spelled correctly, make sure you <a href="#installinglafs">installed the L&amp;F</a> correctly.</p>
50
 
 
51
 
<h2><a name="installinglafs">How do I install new L&amp;F's.</a></h2>
52
 
 
53
 
<p>When you <a href="#morelafs">download</a> a L&amp;F, it should include instructions for installing the L&amp;F.  Some may have requirements that others do not; for example, some will require you to specify additional information on the command line to use the L&amp;F.  Therefore, it is important that you read the instructions that came with your L&amp;F.</p>
54
 
 
55
 
<p>In all cases, however, the L&amp;F must appear in FreeGuide's classpath.  To include the L&amp;F in the classpath, modify the shortcut you are using to start FreeGuide to include the <tt>-classpath</tt> command-line option.  The command line should look something like those shown below (make sure you use the correct locations for your files):</p>
56
 
 
57
 
<p>For Windows</p>
58
 
<pre>
59
 
javaw -classpath "C:\path\to\my\LookAndFeel.jar" -jar "C:\Program Files\FreeGuide\FreeGuide.jar"
60
 
</pre>
61
 
<p>Or, for Unix-like operating systems:</p>
62
 
<pre>
63
 
java -classpath "/path/to/my/LookAndFeel.jar" -jar "/usr/share/freeguide/FreeGuide.jar"
64
 
</pre>
65
 
 
66
 
<h2><a name="whatisgtk+">What about the GTK+ L&amp;F?</a></h2>
67
 
 
68
 
<p>The GTK+ L&amp;F was designed to provide the look and feel of a native application developed with the <a href="http://www.gtk.org/">GTK+</a> toolkit (as are many applications for Unix-like operating systems--such as GNU/Linux--and even some applications that run on Windows).  Since the GTK+ toolkit provides support for themes (which are functionally equivalent to skins), the GTK+ L&amp;F provides theme/skin support.</p>
69
 
 
70
 
<h2><a name="installgtk+">Do I need to install GTK+ to use the GTK+ L&amp;F?</a></h2>
71
 
 
72
 
<p>No.  The GTK+ L&amp;F performs the work normally accomplished by GTK+ theme engines to allow its use on any system--regardless of whether the system uses (or even supports) GTK+.  Therefore, as long as you have the GTK+ L&amp;F <a href="#whereisgtk+">available</a>, you can use the GTK+ L&amp;F. Note that you will also need to <a href="#gtk+themes">make GTK+ themes available</a> to use different GTK+ themes.</p>
73
 
 
74
 
<h2><a name="whereisgtk+">The GTK+ L&amp;F sounds great, but it's not listed as available.  Why not?</a></h2>
75
 
 
76
 
<p>The GTK+ L&amp;F is a brand-new addition to Java.  It is only included in Java 2 version 1.4.2 and above.  Make sure you have the right version of Java.  You can determine your Java version by executing the following command from the Command Prompt or shell:</p>
77
 
 
78
 
<pre>
79
 
java -version
80
 
</pre>
81
 
 
82
 
<p>If you're using Microsoft Windows, please see the <a href="windowsgtk+">next question</a>.</p>
83
 
 
84
 
<h2><a name="windowsgtk+">I have Java 2 version 1.4.2 or above and I still don't see GTK+.  What's wrong?</a></h2>
85
 
 
86
 
<p>Sun decided not to include the GTK+ L&F with the Java 2 Runtime Environment (JRE) for Windows.  Currently, the only available option is to install the <a href="http://java.sun.com/j2se/1.4.2/download.html">Java 2 Software Development Kit (SDK)</a> for Windows.  NOTE:  You do not need the J2EE with J2SE package or the NetBeans IDE with J2SE COBUNDLE.  You want J2SE SDK.</p>
87
 
 
88
 
<p>If you're not using Windows, you may be using an implementation of Java that was created by a vendor other than Sun Microsystems.  If that's the case, you will need to <a href="http://java.sun.com/j2se/1.4.2/download.html">download</a> Sun's implementation of Java to get the GTK+ theme.  If Sun doesn't provide a version for your platform, you're out of (legal) options.</p>
89
 
 
90
 
<h2><a name="moregtk+themes">Where can I get more GTK+ themes?</a></h2>
91
 
 
92
 
<p>GTK+ themes are available from a number of websites, including <a href="http://art.gnome.org/themes/gtk2/">GNOME</a> and <a href="http://themes.freshmeat.net/">freshmeat.net</a>; however, make sure you <a href="#supportedgtk+themes">download supported themes</a>.</p>
93
 
 
94
 
<h2><a name="supportedgtk+themes">My GTK+ theme doesn't look right (or doesn't work).  What's wrong?</a></h2>
95
 
 
96
 
<p>Currently, the GTK+ L&amp;F only supports a subset of the themes available for GTK+.  Themes must be GTK+ 2 themes and may only use the Default, pixmap, and/or bluecurve theme engines.  <a href="#issupportedgtk+theme">What does all that mean?</a>  If you really want to know, I suggest you go to the <a href="http://www.gtk.org/">GTK+</a> website and start reading.  After all, this is a FreeGuide FAQ.  :)</p>
97
 
 
98
 
<h2><a name="issupportedgtk+theme">So, how do I know if a GTK+ theme is supported?</a></h2>
99
 
 
100
 
<p>In truth, the best way to find out is to try the theme.  Even if the theme is not fully supported, you might like the results; and since it is a "Look and Feel," if you like the look and you like the feel, it works for you!</p>
101
 
 
102
 
<h2><a name="gtk+themes">You said the GTK+ L&amp;F supports themes.  How do I change my theme?</a></h2>
103
 
 
104
 
<p>First, you'll need <a href="#moregtk+themes">some themes</a>.  Once you've downloaded one or more themes to try, install the theme (as described in the next two paragraphs).</p>
105
 
 
106
 
<p>If you're using a Unix-like operating system, use the tool provided by your distribution vendor to install and select the theme.  Now, simply start FreeGuide and, if you haven't already done so, select the GTK+ L&amp;F and enjoy the new look.  In general, themes are installed by extracting their files into the <tt>${USER}/.themes</tt> directory.  If you do not have a tool for working with GTK+ themes, <a href="http://www.muhri.net/nav.php3?node=gts">GTK Theme Switch 2</a> is a nice lightweight program for installing and selecting themes.  Note:  If you do not want to install and/or select the theme, you may follow the Windows instructions below.</p>
107
 
 
108
 
<p>If you're using Windows (or you don't want to install the theme on your Unix-like operating system), it's not necessary to install the theme.  Extract the theme files to a directory, keeping each theme in its own directory, and keep all the theme directories together in a single directory to make them easy to find (I recommend using <tt>C:\gtk</tt> since it's short and easy to type).</p>
109
 
 
110
 
<p>Since most of the themes will be distributed in "tarballs" (a common way to distribute software for Unix-like operating systems), you will need an extraction tool that can handle tape archive files (tar files) and GZIP and/or BZIP2 compression.  One such tool for Windows is <a href="http://www.7-zip.org/">7-Zip</a>.</p>
111
 
 
112
 
<p>Once you've extracted the themes, you're ready to use them.  To do so, just specify the location of the <tt>gtkrc</tt> file in the <tt>swing.gtkthemefile</tt> system property on the command line, as shown below:</p>
113
 
 
114
 
<p>For Windows</p>
115
 
<pre>
116
 
javaw -Dswing.gtkthemefile="C:\gtk\Theme Name\gtk-2.0\gtkrc" -jar "C:\Program Files\FreeGuide\FreeGuide.jar"
117
 
</pre>
118
 
<p>Or, for Unix-like operating systems:</p>
119
 
<pre>
120
 
java -Dswing.gtkthemefile="${HOME}/.themes/Theme Name/gtk-2.0/gtkrc" -jar "/usr/share/freeguide/FreeGuide.jar"
121
 
</pre>
122
 
 
123
 
<h2><a name="gtk+changedtheme">Why doesn't FreeGuide notice when I change my System GTK+ theme?</a></h2>
124
 
 
125
 
<p>The GTK+ L&amp;F is not actually using the GTK+ theme engine to draw components of FreeGuide.  Instead, it performs the work normally done by the theme engine itself, but does not detect changes to the system-define theme.  Therefore, to get FreeGuide to notice the change to your theme, simply restart FreeGuide.  Note that future versions of the GTK+ L&amp;F may support detection of changes to the system theme, but until then restarting FreeGuide is the only way to change themes.</p>
126
 
 
127
 
<h2><a name="slow">Since I changed my L&amp;F, FreeGuide seems slow.  Why?</a></h2>
128
 
 
129
 
<p>Well, you can't get something for nothing--with the exception of good quality open source software, of course!  Some L&amp;F's are slower than others, some L&amp;F's claim to be faster than the default Java L&amp;F (Metal), so you might want to try experimenting with <a href="#morelafs">other L&amp;F's</a>.  If you've got your heart set on the L&amp;F you're using, you'll have to get used to its performance.</p>
130
 
 
131
 
<h2><a name="slowerstartup">Since I changed my L&amp;F, FreeGuide seems to take 4.5ms longer to start up.  Why?</a></h2>
132
 
 
133
 
<p>The Java installation on your system specifies a default L&amp;F to use when none is specifically requested.  Therefore, when you start FreeGuide, Java uses its default L&amp;F until FreeGuide changes the L&amp;F to the one you specified in your preferences.  If you tell Java to use your preferred L&amp;F, FreeGuide won't need to change the L&amp;F after startup.</p>
134
 
 
135
 
<p>To specify the L&amp;F, you may either change your installation's default L&amp;F (which will affect <strong>all</strong> Java programs you use) or specify the default L&amp;F on the command line.  To change your installation's default, edit the file <tt>%JAVA_HOME%/lib/swing.properties</tt> (you may have to create the file) and add the line (or edit the one starting with swing.defaultlaf to look like the following):</p>
136
 
 
137
 
<pre>
138
 
swing.defaultlaf=javax.swing.plaf.metal.MetalLookAndFeel
139
 
</pre>
140
 
 
141
 
<p>To change the default L&amp;F for FreeGuide only, specify the L&amp;F classname as the value for the <tt>swing.defaultlaf</tt> system property on the command line.  The command line should look something like those shown below (make sure you use the correct locations for your files):</p>
142
 
 
143
 
<p>For Windows</p>
144
 
<pre>
145
 
javaw -classpath "C:\path\to\my\LookAndFeel.jar" -Dswing.defaultlaf="javax.swing.plaf.metal.MetalLookAndFeel" -jar "C:\Program Files\FreeGuide\FreeGuide.jar"
146
 
</pre>
147
 
<p>Or, for Unix-like operating systems:</p>
148
 
<pre>
149
 
java -classpath "/path/to/my/LookAndFeel.jar" -Dswing.defaultlaf="javax.swing.plaf.metal.MetalLookAndFeel" -jar "/ur/share/freeguide/FreeGuide.jar"
150
 
</pre>
151
 
 
152
 
<p>Note that the Metal L&amp;F is most likely the default on your Java installation, so the above command lines and properties file would do nothing.  Instead, use the fully qualified classname of the L&amp;F you want to use.  The fully qualified classname should be given in the L&amp;F's documentation.</p>
153
 
 
154
 
<h2><a name="morelafs"></a>Where can I find more L&amp;F's?</h2>
155
 
 
156
 
<p>Some sites, such as <a href="http://www.javootoo.com/">javootoo.com</a> provide links to many different L&amp;F's that are available for download under licenses varying from open source to proprietary commercial.  You may also want to try a search on your favorite search engine, for example on <a href="http://www.google.com/search?q=%2B%22Java%22+%2B%22Look+and+Feel%22+%2B%22download%22&start=0&ie=utf-8&oe=utf-8">Google</a>.</p>
157
 
 
158
 
<br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br /><br />
159
 
 
 
7
<h1>Page moved - redirecting</h1>
 
8
<p>This page has moved to <a href="userguide.look_and_feel.html">here</a>.</p>
160
9
</body>
161
10
</html>