private void createAndShowGUI() { //Make sure we have nice window decorations. JFrame.setDefaultLookAndFeelDecorated(true); //Create and set up the window. frame = new JFrame("Stanford Named Entity Recognizer"); frame.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE); frame.getContentPane().setLayout(new BorderLayout()); frame.getContentPane().setSize(WIDTH, HEIGHT); frame.setJMenuBar(addMenuBar()); //frame.setSize(new Dimension(WIDTH, HEIGHT)); frame.setSize(WIDTH, HEIGHT); buildTagPanel(); buildContentPanel(); //Display the window. frame.pack(); frame.setSize(WIDTH, HEIGHT); frame.setVisible(true); }
private void createAndShowGUI() { //Make sure we have nice window decorations. JFrame.setDefaultLookAndFeelDecorated(true); //Create and set up the window. frame = new JFrame("Stanford Named Entity Recognizer"); frame.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE); frame.getContentPane().setLayout(new BorderLayout()); frame.getContentPane().setPreferredSize(new Dimension(WIDTH, HEIGHT)); frame.setJMenuBar(addMenuBar()); buildTagPanel(); buildContentPanel(); buildExtractButton(); extractButton.setEnabled(false); extract.setEnabled(false); //Display the window. frame.pack(); frame.setVisible(true); }
import java.awt.*; import javax.swing.*; public class Test extends JFrame { public Test() { GraphicsEnvironment env = GraphicsEnvironment.getLocalGraphicsEnvironment(); this.setMaximizedBounds(env.getMaximumWindowBounds()); this.setExtendedState(this.getExtendedState() | this.MAXIMIZED_BOTH); } public static void main(String[] args) { JFrame.setDefaultLookAndFeelDecorated(true); Test t = new Test(); t.setVisible(true); } }
checkChoise.add(yesButton); checkChoise.add(noButton); JFrame.setDefaultLookAndFeelDecorated(true); JFrame frame = new JFrame("Are you sure?"); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
/** * Create the GUI and show it. For thread safety, * this method should be invoked from the * event-dispatching thread. */ private static void createAndShowGUI() { //Make sure we have nice window decorations. JFrame.setDefaultLookAndFeelDecorated(true); }
public static void main(String[] args) { JFrame.setDefaultLookAndFeelDecorated(true); SwingUtilities.invokeLater(new Runnable() { public void run() { WordSimlarityUI w = new WordSimlarityUI(); w.setVisible(true); } }); }
package com.firstFrameApp.helloworld; import javax.swing.*; import javax.swing.JFrame; public class helloWorld { public static void main(String[] args) { JFrame.setDefaultLookAndFeelDecorated(true); JFrame frame0 = new JFrame("Hello World Example"); frame0.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); } }
@Override public void run() { try { JFrame.setDefaultLookAndFeelDecorated( true ); JDialog.setDefaultLookAndFeelDecorated( true ); UIManager.setLookAndFeel( className ); } catch ( Exception ex ) { throw new SwingFault( ex.getMessage(), ex ); } }
@Override public void run() { try { JFrame.setDefaultLookAndFeelDecorated( true ); JDialog.setDefaultLookAndFeelDecorated( true ); UIManager.setLookAndFeel( lookAndFeel ); } catch ( Exception ex ) { throw new SwingFault( ex.getMessage(), ex ); } }
private static void createAndShowGUI() { JFrame.setDefaultLookAndFeelDecorated(true); JFrame frame = new JFrame("Sound Detection"); SoundDetectorGui demo = new SoundDetectorGui(); frame.setContentPane(demo.createContentPane()); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); frame.setSize(360, 190); frame.setVisible(true); soundDetector = new SoundDetector(statusIndicator); }
private static void createAndShowGUI() { JFrame.setDefaultLookAndFeelDecorated(true); JFrame frame = new JFrame("Sound Detection"); SoundDetectorGui demo = new SoundDetectorGui(); frame.setContentPane(demo.createContentPane()); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); frame.setSize(360, 190); frame.setVisible(true); soundDetector = new SoundDetector(statusIndicator); }
private static void createAndShowGUI() { JFrame.setDefaultLookAndFeelDecorated(true); JFrame frame = new JFrame("Sound Detection"); SoundDetectorGui demo = new SoundDetectorGui(); frame.setContentPane(demo.createContentPane()); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); frame.setSize(360, 190); frame.setVisible(true); soundDetector = new SoundDetector(statusIndicator); }
/** Initializes the instance centering the dialog on the screen. */ public void initialize() { JFrame.setDefaultLookAndFeelDecorated(true); final Dimension screenSize = Toolkit.getDefaultToolkit(). getScreenSize(); this.initComponents(); this.setLocation(screenSize.width / 2 - this.getWidth() / 2, screenSize.height / 2 - this.getHeight() / 2); }
/** * Called by UIManager when this look and feel is uninstalled. */ @Override public void uninitialize() { removeOurUIs(); resetDefaultBorders(); JFrame.setDefaultLookAndFeelDecorated(false); super.uninitialize(); }
private static void createAndShowGUI() { initLookAndFeel(); //Make sure we have nice window decorations. JFrame.setDefaultLookAndFeelDecorated(true); JDialog.setDefaultLookAndFeelDecorated(true); Main main = new Main(); }
void applyPreferences() { final LAFPreferences prefs = _plugin.getLAFPreferences(); JFrame.setDefaultLookAndFeelDecorated(prefs.getCanLAFSetBorder()); JDialog.setDefaultLookAndFeelDecorated(prefs.getCanLAFSetBorder()); }
public void run() { JFrame.setDefaultLookAndFeelDecorated(true); DroidMainFrame main = new DroidMainFrame(); main.setVisible(false); main.init(); main.setVisible(true); main.checkSignatureUpdates(); main.createDefaultProfile(); } });
public static void main(String[] args) throws Exception { // Change LAF? UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName()); JFrame.setDefaultLookAndFeelDecorated(true); Bug36SmartResizeProblemWhenSrinking example = new Bug36SmartResizeProblemWhenSrinking(); example.go(true); }
public void actionPerformed(ActionEvent e) { Help h = new Help(); h.loadHelp("doc/help/index.htm"); JFrame.setDefaultLookAndFeelDecorated(true); h.helpPane.setCaretPosition(0); h.pack(); h.setExtendedState(JFrame.MAXIMIZED_BOTH); h.show(); } });
private static void initLookAndFeel(ApplicationSettings applicationSettings) { LnfUtil.installLnfs(); String lookFeelClassName = applicationSettings.getLookAndFeelClass(); if (lookFeelClassName != null) { LnfUtil.useLnf(lookFeelClassName); } else { String lookAndFeelClass = LnfUtil.useLnfForPlatform(); applicationSettings.setLookAndFeelClass(lookAndFeelClass); } boolean lookFeelDecorated = applicationSettings.getLookAndFeelDecorated(); JFrame.setDefaultLookAndFeelDecorated(lookFeelDecorated); JDialog.setDefaultLookAndFeelDecorated(lookFeelDecorated); }