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

AWT/2D should read "font.properties.<encoding>" for iso8859-15 support.

XMLWordPrintable

    • 1.1.7a
    • generic
    • solaris_2.6, solaris_9

        Currently all Western European locales choose the fonts from a
        single file, "font.properties".

        With the introduction of support for iso8859-15, it is desirable to
        provide a single file for font properties for these languages when used
        with iso8859-15 encoding, "font.properties.ISO8859_15_FDIS".

        Without this change, several identical copies of these font
        properties will need to be provided for each of the languages involved.
        In addition, languages not directly supported will not be able to default
        to the correct font properties.

        The current JDK1.1 search code (from sun.awt.PlatformFont) tries these
        files in this order:

        $JAVA_HOME/lib/font.properties.<lang>_<region>_<encoding>
        $JAVA_HOME/lib/font.properties.<lang>_<region>
        $JAVA_HOME/lib/font.properties.<lang>_<encoding>
        $JAVA_HOME/lib/font.properties.<lang>
        $JAVA_HOME/lib/font.properties
        $HOME/lib/font.properties.<lang>_<region>_<encoding>
        $HOME/lib/font.properties.<lang>_<region>
        $HOME/lib/font.properties.<lang>_<encoding>
        $HOME/lib/font.properties.<lang>
        $HOME/lib/font.properties

        These should be added (just ahead of the font.properties without suffix):

        $JAVA_HOME/lib/font.properties.<encoding>
        $HOME/lib/font.properties.<encoding>

        The current AWT JDK1.2 search code (from sun.awt.PlatformFont) is the same,
        and must change the same way.

        The current SWING JDK1.2 search code (from sun.java2d.SunGraphicsEnvironment)
        tries these files in this order:

        $HOME/lib/font.properties.<lang>_<region>_<encoding>.<osVersion>
        $HOME/lib/font.properties.<lang>_<region>_<encoding>
        $JAVA_HOME/lib/font.properties.<lang>_<region>_<encoding>.<osVersion>
        $JAVA_HOME/lib/font.properties.<lang>_<region>_<encoding>
        $HOME/lib/font.properties.<lang>_<region>.<osVersion>
        $HOME/lib/font.properties.<lang>_<region>
        $JAVA_HOME/lib/font.properties.<lang>_<region>.<osVersion>
        $JAVA_HOME/lib/font.properties.<lang>_<region>
        $HOME/lib/font.properties.<lang>_<encoding>.<osVersion>
        $HOME/lib/font.properties.<lang>_<encoding>
        $JAVA_HOME/lib/font.properties.<lang>_<encoding>.<osVersion>
        $JAVA_HOME/lib/font.properties.<lang>_<encoding>
        $HOME/lib/font.properties.<lang>.<osVersion>
        $HOME/lib/font.properties.<lang>
        $JAVA_HOME/lib/font.properties.<lang>.<osVersion>
        $JAVA_HOME/lib/font.properties.<lang>
        $HOME/lib/font.properties.<osVersion>
        $HOME/lib/font.properties
        $JAVA_HOME/lib/font.properties.<osVersion>
        $JAVA_HOME/lib/font.properties

        A similar change should be made here.

        Question 1)
        Why are these search paths different????

        Question 2)
        When using the UTF-8 locales, the user could reasonably choose
        either the default (iso8859-1) or the new iso8859-15 font
          properties, depending which characters he wishes to see in his GUI.
        How can he specify?

        Question 3)
        How does a Japanese user display a Euro character in his GUI?
        Does there need to be a Japanese font properties file based on
        iso8859-1 and another based on iso8859-15? And how would he choose?

        This is an immediate problem for JDK1.1.7 and JDK1.2.

              aliusunw Alan Liu (Inactive)
              foliversunw Fred Oliver (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: