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

The number of the font supported with FCS_K is smaller than cricket.

XMLWordPrintable

    • 2d
    • sparc
    • solaris_2.6


      This is found on kestrel Fcs_K euc-ja locale.
      Compile and excute on Solaris GraphicsDeviceTest.java below.

      This is the result compared in OS and every JDK.
      The number of font to display of fcs_K is smaller than jdk1.2.1/1.2.2

                    Solaris2.6 Solaris7 Solaris8
      jdk1.2.1 290 235 373
      jdk1.2.2 290 235 373
      kestrel_fcs_K 284 228 336


      Start GraphicsDeviceTest.java-----------------------

      import java.awt.*;
      import java.awt.event.*;

      public class GraphicsDeviceTest extends Frame {
      private List lst = null;
      private Label lbl = null;

      public GraphicsDeviceTest() {
      super("Graphics Device Test");
      WindowListener l = new WindowAdapter() {
      public void windowClosing(WindowEvent e) { System.exit(0); }
      };
      addWindowListener(l);
      setLayout(new BorderLayout());
      add(lst = new List(), BorderLayout.CENTER);
      add(lbl = new Label(), BorderLayout.SOUTH);
      lbl.setBackground(Color.lightGray);

      // getLocalGraphicsEnvironment()
      GraphicsEnvironment ge = GraphicsEnvironment.getLocalGraphicsEnvironment();
      Font[] fonts = ge.getAllFonts();
      for (int i = 0; i < fonts.length; i++) {
      lst.add("["+i+"]" +fonts[i].toString());
      }

      // getDefaultScreenDevice()
      GraphicsDevice gd = ge.getDefaultScreenDevice();
      String type = "";
      switch (gd.getType()) {
      case GraphicsDevice.TYPE_RASTER_SCREEN:
      type = "RASTER_SCREEN";
      break;
      case GraphicsDevice.TYPE_PRINTER:
      type = "PRINTER";
      break;
      case GraphicsDevice.TYPE_IMAGE_BUFFER:
      type = "IMAGE_BUFFER";
      break;
      }
      lbl.setText("graphics device ID = " + gd.getIDstring() + ", Type = "+ type);
      }

      public static void main(String args[]){
      GraphicsDeviceTest f = new GraphicsDeviceTest();
      f.setSize(480, 300);
      f.show();
      }
      }

      End GraphicsDeviceTest.java-----------------------

      kichi@Japan 1999-10-22

            pkejriwasunw Parry Kejriwal (Inactive)
            eishidasunw Etsuko Ishida (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: