0

I want to apply different themes to the components like jframes, panels, components. I would like to create a theme for working with data from files (XML, JSON or the same).

Vasyl Lyashkevych
  • 1,920
  • 2
  • 23
  • 38
Alex Ferreira
  • 38
  • 1
  • 10
  • Check out [Synth L&F](https://docs.oracle.com/javase/tutorial/uiswing/lookandfeel/synth.html) – Vince May 19 '17 at 17:54
  • thanks. I will read. – Alex Ferreira May 19 '17 at 18:41
  • And what is your question? Telling you about external tools/libraries would be off-topic. Asking how to do it in general a DUP to http://stackoverflow.com/questions/3954616/java-look-and-feel-lf ... so most likely, your question should be put on hold/closed ... – GhostCat May 19 '17 at 19:18

1 Answers1

4

At first, you need to consider a different theme like webapp, desktop GUI using swing components or midi app. It will be related with more criteria.

There are some links for L&F:

  String srt1 = "javax.swing.plaf.metal.MetalLookAndFeel";
  String srt2 = "javax.swing.plaf.nimbus.NimbusLookAndFeel";
  String srt3 = "com.sun.java.swing.plaf.windows.WindowsLookAndFeel";
  String srt4 = "com.sun.java.swing.plaf.windows.WindowsClassicLookAndFeel";
  String srt5 = "com.sun.java.swing.plaf.motif.MotifLookAndFeel";
  String srt6 = "com.sun.java.swing.plaf.gtk.GTKLookAndFeel";
...

EXAMPLE of USING (for example in constructor):

        try {
            UIManager.setLookAndFeel(srt1);
            SwingUtilities.updateComponentTreeUI(this);
        } catch (Exception e) {
            e.printStackTrace();
        }
        JFrame.setDefaultLookAndFeelDecorated(true);
Vasyl Lyashkevych
  • 1,920
  • 2
  • 23
  • 38