All Packages Class Hierarchy This Package Previous Next Index
java.lang.Object | +----multilizer.BaseTranslator | +----multilizer.Translator
Set the Host property to contain the component that the translator translates. In most cases this is the frame where the translator belongs to. Call the translate method to translate the host component.
The DictionaryName property specifies the dictionary that the translator uses to translate the strings. If this is empty the translator uses the default dictionary. The Targets property specifies what components and the properties the translator should translate. If this is empty the translator uses the default targets.
The translator can also update the Locale property of the compoment to match the current locale. If you want to update the Locale properties set the UpdateLocale property true.
An example:
Translator translator = new Translator(); translator.translate(this);
The following paragraphs contain the layout information you need to create containers that can be mirrored.
BorderLayout
Use the BidiBorderLayout instead.
FlowLayout
No special requirements.
GridBagLayout
The container must use only absolute positions (gridx and gridy). If you need to use relative positions use the BidiGridBagLayout instead.
GridLayout
The container must contain at least as many components as the amount of grid cells.
No layout
No special requirements.
Any other layout
Derive a new translator class from this class and override the mirrorContainer method.
public static int LEFT_TO_RIGHT
public static int RIGHT_TO_LEFT
protected static final int MAXGRIDSIZE
public Translator()
public Translator(Dictionary dictionary)
protected boolean doTranslateObject(Object object, RestrictObjectEventObject parentRestriction)
public void setNativeLayout(int value)
public int getNativeLayout()
protected void checkLayout(Container container)
protected void hostTranslated()
protected void mirrorContainer(Container container)
public void setMirror(boolean value)
public boolean getMirror()
All Packages Class Hierarchy This Package Previous Next Index