Skip to content

Commit

Permalink
failed to load "aqualookandfeel" #172
Browse files Browse the repository at this point in the history
  • Loading branch information
walterxie committed Feb 8, 2022
1 parent 156b2d8 commit c249ecc
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions src/tracer/application/TracerApp.java
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,7 @@
import javax.swing.*;
import java.awt.*;
import java.io.File;
import java.lang.reflect.Method;
import java.util.HashSet;
import java.util.Locale;
import java.util.Set;

public class TracerApp extends MultiDocApplication {

Expand Down Expand Up @@ -71,8 +68,16 @@ static public void main(String[] args) {
javax.swing.SwingUtilities.invokeAndWait(new Runnable() {
public void run() {
try {
UIManager.setLookAndFeel("org.violetlib.aqua.AquaLookAndFeel");
lafLoaded = true;
for (UIManager.LookAndFeelInfo info : UIManager.getInstalledLookAndFeels()) {
System.out.println(info.getName() + " - " + info.getClassName());
// Tracer Issue #172 Mac OS X - com.apple.laf.AquaLookAndFeel
if (info.getName().startsWith("Mac")) {
UIManager.setLookAndFeel(info.getClassName());
lafLoaded = true;
}
}
// UIManager.setLookAndFeel("org.violetlib.aqua.AquaLookAndFeel");
// lafLoaded = true;
} catch (Exception e) {
System.err.println("Failed to load AquaLookAndFeel");
}
Expand Down

0 comments on commit c249ecc

Please sign in to comment.