Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4505945

Default component orientation should not be tied to locale

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P3 P3
    • 1.4.0
    • 1.4.0
    • client-libs
    • beta3
    • generic
    • generic

      RFE 4337273 included a feature for setting the default value of a
      JComponent's componentOrientation property based on the setting of that component's
      locale Property.
      This feature was intended to make most programs have the correct orientation
      without the
      programmers having to write any code.

      As a result of Merlin beta feedback from IBM Israel, IBM Egypt and others,
      we realized
      that this feature had a major flaw. The feature breaks down in the
      following way. If a
      program has been translated into a right-to-left language then users expect
      the program to
      have a right-to-left layout. If a program has not been translated however,
      then it is a
      mistake to display left-to-right messages in a right-to-left layout. This
      mismatch of text
      direction and graphical orientation makes the program very difficult to use.
      Due to the
      cost of translation as well as the inevitable delay before a localized
      version is
      available, it is very common for Middle East users to run programs that have
      not been
      translated. Even so, they still run these untranslated programs in their
      Middle East
      locale. In many cases this is just because that is how their environment is
      set up and its
      too much trouble to flip locales back and forth. In other cases, running an
      untranslated
      program in a Middle East locale still gives them access to data formats,
      collation and
      other language features that are necessary for the correct handling of their
      data. Given
      this reality, our new scheme makes it very likely that users will end up
      with programs
      showing English messages in a GUI that is oriented right-to-left.

      This flaw can be seen quite clearly when you consider a Swing application
      that makes use
      of the JOptionPane dialogs, JFileChooser or JColorChooser. Each of these
      components
      includes text messages which need to be localized. Swing provides these
      localizations in
      10 languages, however, this does not include any Middle East languages.
      Under the current
      scheme, a program using these components in a Middle East locale would see
      these
      components oriented right-to-left but with all their text messages in
      English. What's
      worse, this would be true regardless of whether or not the application had
      been localized
      itself because the application must rely on Sun to provide the localizations
      for these
      particular components.


            peytoia Yuka Kamiya (Inactive)
            bcbeck Brian Beck (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: