AdornSample.java Source code

Java tutorial

Introduction

Here is the source code for AdornSample.java

Source

import javax.swing.JFrame;
import javax.swing.JRootPane;

public class AdornSample {

    public static void main(final String args[]) {
        JFrame frame = new JFrame("Adornment Example");
        frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        frame.setUndecorated(true);
        frame.getRootPane().setWindowDecorationStyle(JRootPane.FRAME);
        frame.setSize(300, 100);
        frame.setVisible(true);
    }
}