views:

391

answers:

3

Hi,

I work a lot with look and feel in java and it works well but the only problem that the only component that has no change is the title bar(caption) still have the same native look and feel of os(windows platform as example)

i want to know what's is the reason and how to fix this? any body help..........

thanks in advance

+6  A: 

Check out Substance https://substance.dev.java.net/see.html

You can change the title bar look and feel with substance support.

Here are a few screenshots:

alt text

alt text

Massimo Fazzolari
This is pretty cool, but it might be worth mentioning that it doesn't work in OpenJDK for me. Works with the sun jdk though.
jonescb
Problems only occurs with OpenJDK in Webstart
Massimo Fazzolari
Oh, I was using the Webstart demo. That must have been why.
jonescb
@ Mr Massimo Fazzolari you are right but i use substance look and feel and import the test.jar but still no change title bar still the same (native windows) could you please give me a sample code if you try this before? thanks in advance
ironman
@ironman Substance requires JDK 6.0 or higher. Check out this example https://substance.dev.java.net/docs/getting-started.html
Massimo Fazzolari
A: 

If you want to create your own borderless window, instead of using a Frame/JFrame use a Window/JWindow. Frame/JFrame are extensions to Window/JWindow that provide borders and the maximize, minimize and close buttons. Usually those widgets are provided by the OS, but you can override them.

Cesar
+1  A: 

Some PL&Fs support rendering frame decorations, and some do not. I believe the Sun cross-platform PL&Fs (for instance Metal) support it, but platfrom-specific PL&F (for instance Windows) do not.

The feature is not on by default. To switch it on for all new frames use JFrame.setDefaultLookAndFeelDecorated. The API docs for the method show how to switch it on for frames individually.

Tom Hawtin - tackline