I18N Section Index | Page 6
The basic answer is to use one of the two String constructors that use an encoding argument: String(byte bytes, int offset, int length, String enc) or String(byte bytes, String enc). Because ...more
Where can I find a DecimalFormat that will handle BigDecimals? The JDK docs say that only Longs and Doubles are currently ( 1.3 ) returned.
You can find at least one class that does this at IBM's Alphaworks. See NumberFormat. Unfortunately, as with most items on the site, the license is only for developer experimentation and expires...more
UTF-16 represents every character using two bytes. UTF-8 uses the one byte ASCII character encodings for ASCII characters and represents non-ASCII characters using variable-length encodings. Keep...more
How can I allow input of different decimal symbols, say, 314,4 vs 314.4? And how can I get the value as a number?
The general answer to this is to use NumberFormat and its methods format() and parse(). This will handle the default locale for you. You can also set up a NumberFormat for other locales. Demos ...more
From the sample given at Using Predefined Formats in The Java Tutorial, one might think that getting a TimeInstance with a locale for Germany would do the trick. Unfortunately, this is not the ca...more
The JIL Toolkit was developed by Sun's Technical Development Center. It basically contains four tools with a Swing interface that allow ( quote ): Checking Java files for methods, classes, class...more
How do I change the ComponentOrientation of JOptionPane dialogs created via the static JOptionPane.show<xxx>Dialog or showInternal<xxx>Dialog methods?
No...you can't. That is because the methods are static and therefore you cannot override them. Secondly the class used for JOptionPane is not parametrized. It is hardcoded as JOptionPane. May be, ...more
One of the best places for font links is a british site Fonts that Support Unicode and it appears to be kept reasonably up to date.more
Be sure the JRE installed includes I18N.jar or is localized. There are different download options for the JRE. Under Windows, for example, there is an English and an Internationalized version. ...more
Any recommendations on where to begin study/research on i18n before we start development (websites, articles, books, etc...)?
Here is a selection variety that should help to get you started: Design for Internationalization. - list of books from Java Look and Feel Design Guidelines. From the IBM Developer site, be sure...more
Most database engines support double byte character sets ( DBCS ) and this was the primary method of supporting these languages in the past. While this is generally still available, Unicode is pr...more
How do I alter the reading order of components in a JPanel? When I change a panel's Locale to one with a Right to Left order, the components are still laid out Left to Right.
The general answer in 1.2 or later is to use ResourceBundles and then call Window.applyResourceBundle(). This will do all the grunt work for you so FlowLayout and BorderLayout can take accout of ...more
Locales, as country, regional or area identifiers. Localized Resources, via the ResourceBundle series of classes. Calendars and Time Zones. Formatting, for dates, numbers and decimals, and message...more
Are there any classes to support 'joining' of letters? (For example in Arabic script the letters are joined together according to their state.)
During my research on i18n, I came across International Text in JDK 1.2 which may provide you some better insight. They get into detail of using bidirectional capabilities in Java. Their example ...more
UTF stands for UCS Transformation Format, where UCS stands for Universal Character Set.