This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
Hi, I'm not a good java programmer, and decided to give it another try. I wanted to install a new look and feel and downloaded one from jgooodies, but can't find any READMe files on how to install look and feel or even their FORMS layout.....Sorry for asking such an easy question....
1 - Make sure the jar of the look and feel you want to use is in your CLASSPATH 2 - Call javax.swing.UIManager.setLookAndFeel(String) at the very beginning of your application (Note: this call throws exceptions so you must enclosed it with try/catch block). 3 - Look here for details on laf management.
Thanks for your help. I checked out the link and did what you told me to do, but it doesn't work. I think JGoodies should include how to install it in their README file. When I unpack the file, they have directory with examples. I can run the examples from that directory. But if I copy the example to any other directory, and set the classpath, it doesn't run. It gives me NoClassDefFoundError. I made sure that the jar file is in my classpath.
Thanks for your help. Wanted to try this look and feel because the native look and feel in Linux is too slow and metal is ugghhhhhhhh.
Not sure if this is the problem, but you need to have the actual jar file in your classpath and not just the folder their in.
The prefered way to set the LnF with JGoodies is
or whichever LnF you want.
This is shown in the README.html > Users Guide > Look and Theme
Joined: Feb 16, 2005
I do have actuall jar file in my classpath. In fact, I even tried setting it at compile time like this:
java -classpath .;PATH\lib.jar -jar tiny.jar
tiny.jar is a pre-compile example that comes in the zip file. When I unzip the file, and run it from that directory with that command line, it runs perfectly. However, if I copy the sample file to another directory, and try to run it with the same command line, it gives me the previous error.
Thanks alot Ernest, it worked. It brought a smile to my face when it worked. I've been smashing my head over it for over a day now.
Joined: Feb 16, 2005
Hey guys, thanks alot for your help. You guys are cool. I had heard about javaranch before but it is the first time I gave it a try. This is one cozy ranch. I hope I get my hands dirty cleaning the pen. ;-)
As a side note, the JGoodies 1.2.2 distribution has instructions here:
With Look & Feel instructions:
Increasingly, people seem to misinterpret complexity as sophistication, which is baffling - the incomprehensible should cause suspicion rather than admiration. Possibly this trend results from a mistaken belief that using a somewhat mysterious device confers an aura of power on the user. Niklaus Wirth
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com
subject: How do I install JGoodies Look and Feel??