Showing posts with label bar. Show all posts
Showing posts with label bar. Show all posts

Remove JFrame title bar

Source code below will show you, how to remove title bar from a JFrame.

******************************************************************************
COMPLETE SOURCE CODE FOR : RemoveJFrameTitleBar.java
******************************************************************************


import javax.swing.JFrame;

public class RemoveJFrameTitleBar
{
public static void main(String[]args)
{
//Create a JFrame
JFrame frame=new JFrame();

//Method setUndecorated(true) will eliminate JFrame title bar
frame.setUndecorated(true);

//Set JFrame size to :
//Width : 400 pixels
//Height : 400 pixels
frame.setSize(400,400);

//Make JFrame visible. So we can see it.
frame.setVisible(true);
}
}


******************************************************************************
JUST COMPILE AND EXECUTE IT
******************************************************************************

Create window without title bar and window management button

In java, we can use JWindow to create window without title bar and window management button.

RELAXING NATURE VIDEO