List of usage examples for com.jgoodies.looks.plastic PlasticXPLookAndFeel PlasticXPLookAndFeel
public PlasticXPLookAndFeel()
From source file:FontTest.java
License:Open Source License
private FontSet getPlasticFontSet() { try {/*from w w w . j a v a 2 s . com*/ UIManager.setLookAndFeel(new PlasticXPLookAndFeel()); return PlasticLookAndFeel.getFontPolicy().getFontSet("Plastic", UIManager.getDefaults()); } catch (UnsupportedLookAndFeelException e) { return null; } }
From source file:ch.epfl.lis.gnwgui.GnwGui.java
License:Open Source License
/** * // w w w .j a v a 2s . c o m */ public static void setLookAndFeel() { boolean defautlLAF = GnwGuiSettings.getInstance().useSwingNativeLookAndFeel(); try { if (defautlLAF) { // use the native look and feel UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName()); } else { PlasticLookAndFeel.setPlasticTheme(new Silver()); UIManager.setLookAndFeel("com.jgoodies.looks.plastic.PlasticXPLookAndFeel"); PlasticXPLookAndFeel lookXP = new PlasticXPLookAndFeel(); UIManager.setLookAndFeel(lookXP); } } catch (ClassNotFoundException e) { log.warning("Unable to set Java Look and Feel (ClassNotFoundException): " + e.getMessage()); } catch (InstantiationException e) { log.warning("Unable to set Java Look and Feel (InstantiationException): " + e.getMessage()); } catch (IllegalAccessException e) { log.warning("Unable to set Java Look and Feel (IllegalAccessException): " + e.getMessage()); } catch (UnsupportedLookAndFeelException e) { log.warning("Unable to set Java Look and Feel (UnsupportedLookAndFeelException): " + e.getMessage()); } }
From source file:ch.fork.AdHocRailway.ui.AdHocRailway.java
License:Open Source License
public AdHocRailway(org.apache.commons.cli.CommandLine parsedCommandLine) { super(TITLE); try {//from w w w . ja v a 2 s .co m appContext = new ApplicationContext(); appContext.getMainBus().register(appContext); appContext.getMainBus().register(this); appContext.setMainApp(this); appContext.setMainFrame(this); setUpLogging(); LOGGER.info("****************************************"); LOGGER.info("AdHoc-Railway starting up!!!"); LOGGER.info("****************************************"); PlasticLookAndFeel.setTabStyle(PlasticLookAndFeel.TAB_STYLE_DEFAULT_VALUE); PlasticLookAndFeel.setHighContrastFocusColorsEnabled(false); UIManager.setLookAndFeel(new PlasticXPLookAndFeel()); splash = new SplashWindow(createImageIconFromCustom("splash.png"), this, 500, 12); setIconImage(createImageIconFromCustom("2-Hot-Train-icon 128.png").getImage()); initProceeded("Loading Persistence Layer (Preferences)"); preferences = Preferences.getInstance(); preferences.loadPreferences(parsedCommandLine.hasOption("c")); appContext.setPreferences(preferences); railwayDeviceManager = new RailwayDeviceManager(appContext); appContext.setRailwayDeviceManager(railwayDeviceManager); railwayDeviceManager.loadControlLayer(); persistenceManager = new PersistenceManager(appContext); persistenceManager.loadPersistenceLayer(); initProceeded("Creating GUI ..."); initGUI(); disableEnableMenuItems(); LOGGER.info("Finished Creating GUI"); splash.setVisible(false); persistenceManager.loadLastFileOrLoadDataFromAdHocServerIfRequested(); updateGUI(); railwayDeviceManager.autoConnectToRailwayDeviceIfRequested(); setSize(1600, 1000); initProceeded("AdHoc-Railway started"); updateCommandHistory("AdHoc-Railway started"); Thread.setDefaultUncaughtExceptionHandler(new Thread.UncaughtExceptionHandler() { @Override public void uncaughtException(final Thread t, final Throwable e) { handleException(e); } }); setLocationByPlatform(true); setVisible(true); } catch (final Exception e) { handleException(e); } }
From source file:ch.hsr.audiotagger.AudioTaggerApplication.java
License:Open Source License
public static void main(String[] args) throws Exception { /* Vorbereiten: */ initSettings();//ww w .ja va2s. c o m boolean isMac = false; if (Settings.getInstance().getBoolean(Settings.KEY_COMMON_ENABLE_MAC_DETECTION)) { isMac = isMac(); } /* Look&Feel: */ if (!isMac) { try { PlasticLookAndFeel.setPlasticTheme(new SkyBlue()); UIManager.setLookAndFeel(new PlasticXPLookAndFeel()); } catch (UnsupportedLookAndFeelException e) { e.printStackTrace(); } } else { try { UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName()); } catch (UnsupportedLookAndFeelException e) { e.printStackTrace(); } } GUIImageManager.loadImageManager("/ch/hsr/audiotagger/ui/res/"); /* Platformspezifisches AudioTaggerFrame instanzieren und anzeigen: */ AudioTaggerFrame frame = null; if (isMac) frame = new MacAudioTaggerFrame(); else frame = new UniversalAudioTaggerFrame(); frame.setVisible(true); }
From source file:com.angrysnail.sheeta.svgeditor.Editor.java
License:LGPL
/** * The constructor of the class//from w w w.j a v a 2 s . co m */ public Editor() { try { PlasticXPLookAndFeel laf = new PlasticXPLookAndFeel(); PlasticLookAndFeel.set3DEnabled(true); UIManager.setLookAndFeel(laf); } catch (Exception e) { } editor = this; }
From source file:com.archivas.clienttools.arcmover.gui.HCPDataMigrator.java
License:Open Source License
public static void main(String[] args) { try {/*w ww . j av a 2s. c o m*/ for (Map.Entry<Object, Object> prop : System.getProperties().entrySet()) { LOG.log(Level.INFO, "System Property: " + prop.getKey() + "=" + prop.getValue()); } PlasticXPLookAndFeel.setPlasticTheme(new ExperienceBlue()); PlasticLookAndFeel.setPlasticTheme(new ExperienceBlue()); UIManager.setLookAndFeel(new PlasticXPLookAndFeel()); // Change label texts per UI bug #21966 UIManager.put(FILE_CHOOSER_LOOK_IN_LABEL_TEXT_PROPERTY, UIManager.getString(FILE_CHOOSER_LOOK_IN_LABEL_TEXT_PROPERTY).replace(":", "")); UIManager.put(FILE_CHOOSER_FILE_NAME_LABEL_TEXT_PROPERTY, UIManager.getString(FILE_CHOOSER_FILE_NAME_LABEL_TEXT_PROPERTY).replace(":", "")); UIManager.put(FILE_CHOOSER_FILES_OF_TYPE_LABEL_TEXT_PROPERTY, UIManager.getString(FILE_CHOOSER_FILES_OF_TYPE_LABEL_TEXT_PROPERTY).replace(":", "")); } catch (Exception e) { LOG.warning("" + e); throw new RuntimeException(e); } SplashDialog splash = new SplashDialog(); try { validateLaunchOK(splash); upgrade(splash); new HCPDataMigrator(splash); } catch (StorageAdapterException e) { LOG.warning("" + e); throw new RuntimeException(e); } }
From source file:com.eviware.soapui.StandaloneSoapUICore.java
License:EUPL
public void initSoapUILookAndFeel() { try {// w ww. j ava 2 s . com // Enabling native look & feel by default on Mac OS X if (UISupport.isMac()) { javax.swing.UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName()); getSettings().setBoolean(UISettings.NATIVE_LAF, true); log.info("Defaulting to native L&F for Mac OS X"); } else if (getSettings().getBoolean(UISettings.NATIVE_LAF)) { javax.swing.UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName()); } else { SoapUITheme theme = new SoapUITheme(); PlasticXPLookAndFeel.setCurrentTheme(theme); PlasticXPLookAndFeel.setTabStyle("Metal"); UIManager.setLookAndFeel(new PlasticXPLookAndFeel()); UIManager.put("TabbedPane.tabAreaInsets", new Insets(3, 2, 0, 0)); UIManager.put("TabbedPane.unselectedBackground", new Color(220, 220, 220)); UIManager.put("TabbedPane.selected", new Color(240, 240, 240)); PlasticXPLookAndFeel.setPlasticTheme(theme); } } catch (Exception e) { SoapUI.logError(e, "Error initializing Look and Feel"); } }
From source file:com.floreantpos.main.Application.java
License:Open Source License
private void setApplicationLook() { try {//from w w w . jav a 2 s.c om PlasticXPLookAndFeel.setPlasticTheme(new ExperienceBlue()); UIManager.setLookAndFeel(new PlasticXPLookAndFeel()); initializeFont(); } catch (Exception ignored) { } }
From source file:com.floreantpos.main.SetUpWindow.java
License:Open Source License
private void setLookAndFeel() { try {//from w ww . ja va 2 s.c o m PlasticXPLookAndFeel.setPlasticTheme(new ExperienceBlue()); UIManager.setLookAndFeel(new PlasticXPLookAndFeel()); initializeFont(); } catch (Exception ignored) { } }
From source file:com.frinika.FrinikaMain.java
License:Open Source License
private static void configureUI() { String lcOSName = System.getProperty("os.name").toLowerCase(); try {/*from ww w .j av a 2s . co m*/ UIManager.setLookAndFeel(new PlasticXPLookAndFeel()); } catch (Exception e) { e.printStackTrace(); } }