-1

I spend hours in searching about changing jTabbedPane alignment from left to right as following:

screen shot: right alignment

screen shot: left alignment

1 Answers1

0

This to make tabs from right to left look at method setComponentOrientation(ComponentOrientation.RIGHT_TO_LEFT);

JFrame frame = new JFrame("Frame Test");
        frame.setMinimumSize(new Dimension(500, 500));

        JTabbedPane tapPane = new JTabbedPane();
        tapPane.setComponentOrientation(ComponentOrientation.RIGHT_TO_LEFT);
        tapPane.insertTab("Tab1", null, new JTextField("test"), "Tab1 tip", 0);

        frame.add(tapPane);
        frame.show();
Omar
  • 64
  • 4