@@ -170,58 +170,64 @@ static public void main(String[] args) {
170170 System .setProperty ("swing.aatext" , "true" );
171171
172172 System .setProperty ("apple.awt.graphics.UseQuartz" , "true" );
173- System .setProperty ("apple.awt.antialiasing" ,"true" );
174- System .setProperty ("apple.awt.rendering" ,"VALUE_RENDER_QUALITY" );
175-
176- System .setProperty ("apple.laf.useScreenMenuBar" ,"true" );
177- System .setProperty ("apple.awt.draggableWindowBackground" ,"true" );
178- System .setProperty ("apple.awt.showGrowBox" ,"true" );
179-
180- try {
181- // set the Quaqua Look and Feel in the UIManager
182- javax .swing .SwingUtilities .invokeAndWait (new Runnable () {
183- public void run () {
184- try {
185- System .setProperty (
186- "Quaqua.design" ,"Sierra"
187- );
173+ System .setProperty ("apple.awt.antialiasing" , "true" );
174+ System .setProperty ("apple.awt.rendering" , "VALUE_RENDER_QUALITY" );
188175
189- try {
190- // We need to do this using dynamic class loading to avoid other platforms
191- // having to link to this class. If the Quaqua library is not on the classpath
192- // it simply won't be used.
193- Class <?> qm = Class .forName ("ch.randelshofer.quaqua.QuaquaManager" );
194- //
195- // Method method = qm.getMethod("setIncludedUIs", Set.class);
196- // Set<String> includes = new HashSet<String>();
197- // includes.add("ColorChooser");
198- // includes.add("FileChooser");
199- // includes.add("Button");
200- // includes.add("SplitPane");
201- // includes.add("Table");
202- // includes.add("Panel");
203- // method.invoke(null, includes);
204-
205- Method method = qm .getMethod ("setExcludedUIs" , Set .class );
206- Set <String > excludes = new HashSet <String >();
207- excludes .add ("RootPane" );
208- // excludes.add("Table");
209- excludes .add ("TextField" );
210- method .invoke (null , excludes );
211-
212- }
213- catch (Throwable e ) {
214- }
176+ System .setProperty ("apple.laf.useScreenMenuBar" , "true" );
177+ System .setProperty ("apple.awt.draggableWindowBackground" , "true" );
178+ System .setProperty ("apple.awt.showGrowBox" , "true" );
215179
216- //set the Quaqua Look and Feel in the UIManager
217- UIManager .setLookAndFeel ("ch.randelshofer.quaqua.QuaquaLookAndFeel" );
218- lafLoaded = true ;
219- } catch (Exception e ) {
220- }
221- }
222- });
223- } catch (Exception e ) {
224- }
180+ // int javaVersion = Integer.parseInt(System.getProperty("java.version").split("\\.")[0]);
181+ //
182+ // System.out.println("Java version: " + javaVersion);
183+ //
184+ //
185+ // if (javaVersion < 10) {
186+ // try {
187+ // // set the Quaqua Look and Feel in the UIManager
188+ // javax.swing.SwingUtilities.invokeAndWait(new Runnable() {
189+ // public void run() {
190+ // try {
191+ // System.setProperty(
192+ // "Quaqua.design", "Sierra"
193+ // );
194+ //
195+ // try {
196+ // // We need to do this using dynamic class loading to avoid other platforms
197+ // // having to link to this class. If the Quaqua library is not on the classpath
198+ // // it simply won't be used.
199+ // Class<?> qm = Class.forName("ch.randelshofer.quaqua.QuaquaManager");
200+ //
201+ //// Method method = qm.getMethod("setIncludedUIs", Set.class);
202+ //// Set<String> includes = new HashSet<String>();
203+ ////// includes.add("ColorChooser");
204+ ////// includes.add("FileChooser");
205+ //// includes.add("Button");
206+ //// includes.add("SplitPane");
207+ //// includes.add("Table");
208+ //// includes.add("Panel");
209+ //// method.invoke(null, includes);
210+ //
211+ // Method method = qm.getMethod("setExcludedUIs", Set.class);
212+ // Set<String> excludes = new HashSet<String>();
213+ // excludes.add("RootPane");
214+ //// excludes.add("Table");
215+ // excludes.add("TextField");
216+ // method.invoke(null, excludes);
217+ //
218+ // } catch (Throwable e) {
219+ // }
220+ //
221+ // //set the Quaqua Look and Feel in the UIManager
222+ // UIManager.setLookAndFeel("ch.randelshofer.quaqua.QuaquaLookAndFeel");
223+ // lafLoaded = true;
224+ // } catch (Exception e) {
225+ // }
226+ // }
227+ // });
228+ // } catch (Exception e) {
229+ // }
230+ // }
225231
226232 UIManager .put ("SystemFont" , new Font ("Lucida Grande" , Font .PLAIN , 13 ));
227233 UIManager .put ("SmallSystemFont" , new Font ("Lucida Grande" , Font .PLAIN , 11 ));
0 commit comments