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

need seperate message for label text of open button in both basic and metal LookAndFeel

    Details

      Description

      In Metal LookAndFeel, the open button of JFileChooser dialog should not have mnemonics. In Windows LookAndFeel, the open button of JFileChooser dialog should have mnemonics. In asian locales, unlike in western locales, the label text of the open button is sthing like "Open(O)" to display the option of mnemonic key.

      Currently, in j2se/src/share/classes/com/sun/swing/internal/plaf/basic/resources/basic.properties, following two keys are used to display lable text of open button:
      FileChooser.openButtonText=Open
      FileChooser.directoryOpenButtonText=Open

      In Asian locales (Chinese, Japanese, Korean), to make the label text shown correctly in metal look and feel(do not display (O)), the text should be "Open". While, to make the label text show correctly in windows look and feel, the text should be "Open(O)". So one key in basic.properties is not enough.

      The above two keys should also be in j2se/src/share/classes/com/sun/swing/internal/plaf/metal/resources/metal.properties. When the JFileChooser dialog is opened in metal look and feel, the button label text will be loaded from metal.properties, showing "Open". When the JFileChooser dialog is opened in windows look and feel, the button lable text will be loaded from basic.properties, showing "Open(O)".

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                yhuang Yong Huang
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Imported:
                  Indexed: