开发者

Internal JFrame Properties

开发者 https://www.devze.com 2023-03-23 13:54 出处:网络
I have a JInternalFrame as shown below. Are there properties that allow for? coloring hiding the title bar

I have a JInternalFrame as shown below.

Internal JFrame Properties

Are there properties that allow for?

  • coloring
  • hiding the title bar
  • adding text
  • Further Customization*

to开发者_开发百科 the top bar?

The only thing I have been able to find is:

jInternalFrame1.setTitle("Hello");

But I am more after a way to hide it etc.


you can set through it's constructor like button maximize, minimize, resize, icon etc

and http://www.roseindia.net/answers/viewqa/Java-Beginners/1923-Hide/remove-titlebar-of-JInternalframe.html

another example with multiple JInternalFrame


To remove all the decorations from the title bar you can create a smaller bar (in height) that will only allow the user to drag the internal frame:

frame.putClientProperty("JInternalFrame.isPalette", Boolean.TRUE);

To remove the title bar when using the Metal LAF you can use something like:

BasicInternalFrameUI ui = (BasicInternalFrameUI)frame.getUI();
Component north = ui.getNorthPane();
north.setPreferredSize( new Dimension(0, 0) );
north.validate();
0

精彩评论

暂无评论...
验证码 换一张
取 消