![]() |
ubuntu.com - launchpad.net - ubuntu help
|
|
|||||||
Hello, Unregistered You are browsing a READ only archive of the main support categories pre 4/21/2008. You will not be able to post or reply any threads in this section.
Ubuntu 9.10 is out!!!
When downloading Ubuntu 9.10 please consider using bittorrent to get your copy of Ubuntu. The Ubuntu Developers Summit for Lucid Lynx will be held the week of 16-Nov-2009 till 20-Nov-2009 in Dallas, TX USA. Visit the the Ubuntu wiki for more information about UDS and how to participate remotely. |
|
Desktop Environments Support for your Ubuntu desktop. Including Gnome, KDE and XFCE. |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
A Carafe of Ubuntu
![]() Join Date: May 2005
Beans: 96
|
Gnome forcing a crappy Java look and feel
So I am running a couple of Java applications, but when running it in Gnome, a crappy-looking excuse for an attempt to emulate Gtk is selected as the default look and feel for each app. However, since the default look and feel shows up in other environments (e.g., the default showed up when running fluxbox), I am fairly sure this is a Gnome issue.
I searched with gconf-editor, but there doesn't appear to be anything with the name 'java' in it anywhere. Any idea what's forcing this and how I can unforce it? |
|
|
|
|
|
#2 | |
|
Skinny Soy Caramel Ubuntu
![]() |
Re: Gnome forcing a crappy Java look and feel
Quote:
|
|
|
|
|
|
|
#3 |
|
Ubuntu Extra Shot
![]() |
Re: Gnome forcing a crappy Java look and feel
No, what he is talking about is java programs attempting to look like gtk2 apps, and doing a poor job of it. The themes that are supported actually work pretty well. It doesn't really have anything to do with gnome, so there won't be any settings for it. There might be some sort of java config.
I don't really know what you can do about it. Java apps are probably going to look ugly no matter what. |
|
|
|
|
|
#4 |
|
Quad Shot of Ubuntu
![]() Join Date: Mar 2005
Beans: 407
|
Re: Gnome forcing a crappy Java look and feel
Talk to the developers of whatever software it is you're using. It has come to the attention of the Art of Illusion devs that the GTK look and feel is not going to work, so they're considering using (IIRC) jgoodies. I have no idea how it all works, but apparently jgoodies will only be used instead of the GTK laf, and not in other cases.
Good question, and the answer seems to be: Talk to your developers. |
|
|
|
|
|
#5 |
|
A Carafe of Ubuntu
![]() Join Date: May 2005
Beans: 96
|
Re: Gnome forcing a crappy Java look and feel
No, the answer is not really "talk to the developers" simply because the application does not select a look and feel. Therefore, if something is being forced to use one that is not the default one for Java (instead a default one set elsewhere), then something is wrong other than with the application itself.
|
|
|
|
|
|
#6 |
|
Gee! These Aren't Roasted!
![]() Join Date: May 2005
Beans: 192
|
Re: Gnome forcing a crappy Java look and feel
This comes from the Sun web site. Maybe it will help you out:
Specifying the Look and Feel: Command Line You can specify the look and feel at the command line by using the -D flag to set the swing.defaultlaf property. For example: java -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKL ookAndFeel MyApp java -Dswing.defaultlaf=com.sun.java.swing.plaf.windows. WindowsLookAndFeel MyApp Specifying the Look and Feel: swing.properties Yet another way to specify the current look and feel is to use the swing.properties file to set the swing.defaultlaf property. This file is located in the lib directory of the Java release. For example, if you're using the Java interpreter in javaHomeDirectory\bin, then the swing.properties file (if it exists) is in javaHomeDirectory\lib. Here is an example of the contents of a swing.properties file: # Swing properties swing.defaultlaf=com.sun.java.swing.plaf.windows.W indowsLookAndFeel How the UI Manager Chooses the Look and Feel Here are the look-and-feel determination steps that occur when the UI manager first initializes itself: 1. If the program sets the look and feel before any components are created, the UI manager tries to create an instance of the specified look-and-feel class. If successful, all components use that look and feel. 2. If the program hasn't successfully specified a look and feel, then the UI manager uses the look and feel specified by the swing.defaultlaf property. If the property is specified in both the swing.properties file and on the command line, the command-line definition takes precedence. 3. If none of these steps has resulted in a valid look and feel, the program uses the Java look and feel. Steve |
|
|
|
|
|
#7 |
|
A Carafe of Ubuntu
![]() Join Date: May 2005
Beans: 96
|
Re: Gnome forcing a crappy Java look and feel
That may be helpful. I'll take a closer look at that later. I guess I should've checked Sun's site before automatically assuming a Gnome problem...
Thanks. |
|
|
|
|
|
#8 | |
|
A Carafe of Ubuntu
![]() Join Date: May 2005
Beans: 96
|
Re: Gnome forcing a crappy Java look and feel
Quote:
Later on tonight, I'll whip up a test program and try that and see what happens. |
|
|
|
|
|
|
#9 |
|
A Carafe of Ubuntu
![]() Join Date: May 2005
Beans: 96
|
Re: Gnome forcing a crappy Java look and feel
So I really feel dumb.
I know I have seen this before with various applications, so that's why I thought that it was a Gnome-related issue. However, browsing the source of this particular program I am running, it makes a call to Code:
UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName()); I also apologize for my idiocy. |
|
|
|
|
|
#10 |
|
Quad Shot of Ubuntu
![]() Join Date: Mar 2005
Beans: 407
|
Re: Gnome forcing a crappy Java look and feel
Apology accepted, Strife!
|
|
|
|
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|