Skip to content
Advertisement

How to get macOS Mojave Style Dark Mode in Java in a Swing Application?

I want to know if there is some way to get macOS Mojave style Dark Mode in a swing application in Java?

I want to get macOS Mojave Style Dark Mode on a JFrame in a Java Swing Application.

Please let me know.

Thanks

Asrar Bashir Sunge

Advertisement

Answer

I guess, you might give it a try to use Darcula:

https://github.com/Revivius/nb-darcula

https://github.com/bulenkov/Darcula

import com.bulenkov.darcula.*;
...
...
BasicLookAndFeel darculaLookAndFeel = new DarculaLaf();
try {
  UIManager.setLookAndFeel(darculaLookAndFeel);
} catch (UnsupportedLookAndFeelException ex) {
  // ups!
}

enter image description here

User contributions licensed under: CC BY-SA
6 People found this is helpful
Advertisement