Package java.awt

Examples of java.awt.Font


     * @param o1 font 2.
     * @return an integer representing the relative order of the two fonts.
     */
    public int compare(final Object o, final Object o1)
    {
      final Font f1 = (Font) o;
      final Font f2 = (Font) o1;
      int comp = f1.getFamily().compareTo(f2.getFamily());
      if (comp == 0)
      {
        comp = f1.getName().compareTo(f2.getName());
      }
      return comp;
    }
View Full Code Here


      {
        chartTitle.setFont(getPieTitleFont());
      }
      else
      {
        final Font titleFont = Font.decode(getTitleFont());
        chartTitle.setFont(titleFont);
      }
    }

    if (isAntiAlias() == false)
View Full Code Here

          /* Dispose the dialog, "setVisible(true)" method will return */
          dispose();
        }
      });

      Font f = new Font("Monospaced", Font.PLAIN, 16);

      terminalArea = new JTextArea(y, x);
      terminalArea.setFont(f);
      terminalArea.setBackground(Color.BLACK);
      terminalArea.setForeground(Color.ORANGE);
View Full Code Here

    moduleNameField = new JTextArea();
    moduleNameField.setName("ModuleNameField"); //$NON-NLS-1$
    moduleNameField.setMinimumSize(new Dimension(100, 10));
    moduleNameField.setEditable(false);
    moduleNameField.setLineWrap(false);
    moduleNameField.setFont(new Font("SansSerif", //$NON-NLS-1$
        Font.BOLD, moduleNameField.getFont().getSize() + 4));

    producerField = new JTextArea();
    producerField.setName("ProducerField"); //$NON-NLS-1$
    producerField.setMinimumSize(new Dimension(100, 10));
View Full Code Here

                            true,
                            true));       
        getSettings().addSetting(_Font,
                new Setting(DcRepository.ValueTypes._FONT,
                            DcRepository.Settings.stSystemFontNormal,
                            new Font("Arial", Font.PLAIN, 11),
                            ComponentFactory._FONTSELECTOR,
                            "tpFont",
                            "lblFontNormal",
                            false,
                            true));
        getSettings().addSetting(_Font,
                new Setting(DcRepository.ValueTypes._FONT,
                            DcRepository.Settings.stSystemFontBold,
                            new Font("Arial", Font.PLAIN, 11),
                            ComponentFactory._FONTSELECTOR,
                            "tpFont",
                            "lblFontBold",
                            false,
                            true));
View Full Code Here

        (ConfigDescriptionEditor.EDITOR_FONT_KEY, "Monospaced"); //$NON-NLS-1$
    final int fontSize = ParserUtil.parseInt
        (ConfigEditorBoot.getInstance().getGlobalConfig().getConfigProperty
            (ConfigDescriptionEditor.EDITOR_FONT_SIZE_KEY), 12);
    descriptionField = new JTextArea();
    descriptionField.setFont(new Font(font, Font.PLAIN, fontSize));
    descriptionField.setLineWrap(true);
    descriptionField.setWrapStyleWord(true);
    keyNameField = new JTextField();

    final JPanel enumerationEditor = createEnumerationEditor();
View Full Code Here

    }

//## AWT begin ##
    private void loadFont() {
        if (isWindows) {
            font = new Font("Dialog", Font.PLAIN, 11);
        } else {
            font = new Font("Dialog", Font.PLAIN, 12);
        }
    }
View Full Code Here

    private void fontChanged() {
        final String fontName = Core.frostSettings.getValue(SettingsClass.FILE_LIST_FONT_NAME);
        final int fontStyle = Core.frostSettings.getIntValue(SettingsClass.FILE_LIST_FONT_STYLE);
        final int fontSize = Core.frostSettings.getIntValue(SettingsClass.FILE_LIST_FONT_SIZE);
        Font font = new Font(fontName, fontStyle, fontSize);
        if (!font.getFamily().equals(fontName)) {
            logger.severe("The selected font was not found in your system\n" +
                           "That selection will be changed to \"SansSerif\".");
            Core.frostSettings.setValue(SettingsClass.FILE_LIST_FONT_NAME, "SansSerif");
            font = new Font("SansSerif", fontStyle, fontSize);
        }
        modelTable.setFont(font);
    }
View Full Code Here

            fontStyle = Font.BOLD & Font.ITALIC;
            break;
        }

        omTxt.setFillPaint(foreColor);
        omTxt.setFont(new Font(fontName.substring(1, fontName.length() - 1), fontStyle, 10));
    }
View Full Code Here

    /**
     * render labels
     */
    protected void renderLabels(Graphics g) {
        Font f = getFont();
        Paint labelPaint = getLabelPaint();
        Paint mattingPaint = getMattingPaint();
        boolean isMatted = isMatted();
        for (Iterator it = labels.iterator(); it.hasNext();) {
            OMText text = (OMText) it.next();
View Full Code Here

TOP

Related Classes of java.awt.Font

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.