Package java.awt

Examples of java.awt.Font$FontAccessImpl


    Object      result;
    Vector      children;
    Element     child;
    int         i;
    String      name;
    Font        font;

    // for debugging only
    if (DEBUG)
       trace(new Throwable(), node.getAttribute(ATT_NAME));
View Full Code Here


    return newVector.elements();
  }

  private JScrollPane makePanel() {
    String fontFamily = this.getFont().getFamily();
    Font newFont = new Font(fontFamily, Font.PLAIN, 10);
    JPanel hp = new JPanel();
    hp.setFont(newFont);
    int numPlots = Math.min(m_visualizeDataSet.numAttributes(), m_maxPlots);
    int gridHeight = numPlots / m_gridWidth;
   
View Full Code Here

    // create the chart
    JFreeChart pieChart = ChartFactory.createPieChart("Open Tickets by User", pieData, true, true, false);

    // add the "Total Open Tickets" sub-title
    TextTitle t1 = new TextTitle("Total Open Tickets: " + String.valueOf(totalTickets),
                                 new Font("SansSerif", Font.PLAIN, 11));
    pieChart.addSubtitle(t1);

    // set the chart visual options
    PiePlot plot = (PiePlot)pieChart.getPlot();
    plot.setForegroundAlpha(0.65f);
View Full Code Here

              cellHasFocus);
          // Initialize fonts if not done
          if (this.defaultFont == null) {
            this.defaultFont = getFont();
            this.supportedLanguageFont =
                new Font(this.defaultFont.getFontName(), Font.BOLD, this.defaultFont.getSize());
           
          }
          setFont(library.getSupportedLanguages().contains(locale.toString())
              ? supportedLanguageFont : defaultFont);
          return this;
View Full Code Here

    int theHeight = theAlertIcon.getHeight(this);
    alertY = ((this.getBounds().height - theHeight) / 2);
   
    linkX = alertX + theAlertIcon.getWidth(this) + Integer.parseInt(getParameter("padding-text"));
   
    fontAlert = new Font(getParameter("font-face"), AlertUtil.getFontStyle(getParameter("font-style")), Integer.parseInt(getParameter("font-size")));
    this.setFont(fontAlert);
    linkY = (this.getBounds().height + this.getFontMetrics(this.getFont()).getHeight() / 2) / 2;
    textColor = Color.decode(this.getParameter("text-color"));
    timeSleep = Integer.parseInt(getParameter("time-sleep"));
   
    timeUpdate= Integer.parseInt(getParameter("time-update"));
    noAlerts = getParameter("no-alerts");
    alertLength = Integer.parseInt(getParameter("alert-length"));
   
    dismissPadding = Integer.parseInt(getParameter("dismiss-padding"));
    dismissText = new TextLink(getParameter("dismiss-text"), getParameter("dismiss-tooltip"));
    fontDismiss = new Font(getParameter("dismiss-font-face"), AlertUtil.getFontStyle(getParameter("dismiss-font-style")), Integer.parseInt(getParameter("dismiss-font-size")));
   
    URL hostURL = getCodeBase();
    String hostName = hostURL.getHost();
    int port = hostURL.getPort();
   
View Full Code Here

        super.updateUI();
        setBackground(UIManager.getColor("TextArea.background"));
        setForeground(UIManager.getColor("TextArea.foreground"));
        if (UIManager.getLookAndFeel().getID().equals("MacOS")) {
            setFont(
                new Font("Monospaced",Font.PLAIN,10)
            );
        } else {
            setFont(
                new Font("Monospaced",Font.PLAIN,12)
            );
        }
    }
View Full Code Here

        new Color(143, 0, 0),
        new Color(48, 0, 96),
        new Color(48, 0, 96),
    };
    font = new Font[] {
        new Font("Sans Serif", Font.ITALIC, 20),
        new Font("Sans Serif", Font.BOLD, 24),
        new Font("Sans Serif", Font.BOLD, 18),
    };
    paintSteady = new Paint[colorBase.length];
    for (int i = 0; i < colorBase.length; i++) {
      Color hue = colorBase[i];
      paintSteady[i] = new GradientPaint(0.0f, 0.0f, derive(hue, 0),
View Full Code Here

    } else if (attr == StdAttr.LABEL) {
      String val = (String) value;
      label = val;
      fireAttributeValueChanged(StdAttr.LABEL, val);
    } else if (attr == StdAttr.LABEL_FONT) {
      Font val = (Font) value;
      labelFont = val;
      fireAttributeValueChanged(StdAttr.LABEL_FONT, val);
    } else if (attr == LABEL_LOCATION_ATTR) {
      Direction val = (Direction) value;
      labelLocation = val;
View Full Code Here

    String fontSize = elt.getAttribute("font-size");
    int styleFlags = 0;
    if (fontStyle.equals("italic")) styleFlags |= Font.ITALIC;
    if (fontWeight.equals("bold")) styleFlags |= Font.BOLD;
    int size = Integer.parseInt(fontSize);
    ret.setValue(DrawAttr.FONT, new Font(fontFamily, styleFlags, size));
   
    String alignStr = elt.getAttribute("text-anchor");
    AttributeOption halign;
    if (alignStr.equals("start")) {
      halign = DrawAttr.ALIGN_LEFT;
View Full Code Here

      g.setColor(Color.BLACK);
     
    }
   
    private void paintString(Graphics g, String msg) {
      Font old = g.getFont();
      g.setFont(old.deriveFont(Font.BOLD).deriveFont(18.0f));
      FontMetrics fm = g.getFontMetrics();
      int x = (getWidth() - fm.stringWidth(msg)) / 2;
      if (x < 0) x = 0;
      g.drawString(msg, x, getHeight() - 23);
      g.setFont(old);
View Full Code Here

TOP

Related Classes of java.awt.Font$FontAccessImpl

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.