To support multilingual and decide the component orientation at runtime, set the components locale and orientation at runtime. - Java Swing

Java examples for Swing:FlowLayout

Introduction

To globally set the default locale for all Swing components in your application.

Demo Code

import java.util.Locale;

import javax.swing.JComponent;

public class Main {
  public static void main(String[] argv) throws Exception {
    // "ar" is used for Arabic locale
    JComponent.setDefaultLocale(new Locale("ar"));
  }/*w w w.  j  a  v  a  2  s.  c  om*/
}

Related Tutorials