Package java.awt

Examples of java.awt.BasicStroke$BufferedPath


      return null;
    }

    if (BorderStyle.DASHED.equals(edge.getBorderStyle()))
    {
      return new BasicStroke(effectiveWidth, BasicStroke.CAP_SQUARE,
          BasicStroke.JOIN_MITER,
          10.0f, new float[]
              {6 * effectiveWidth, 6 * effectiveWidth}, 0.0f);
    }
    if (BorderStyle.DOTTED.equals(edge.getBorderStyle()))
    {
      return new BasicStroke(effectiveWidth, BasicStroke.CAP_SQUARE,
          BasicStroke.JOIN_MITER,
          5.0f, new float[]{0.0f, 2 * effectiveWidth}, 0.0f);
    }
    if (BorderStyle.DOT_DASH.equals(edge.getBorderStyle()))
    {
      return new BasicStroke(effectiveWidth, BasicStroke.CAP_SQUARE,
          BasicStroke.JOIN_MITER,
          10.0f, new float[]
              {0, 2 * effectiveWidth, 6 * effectiveWidth, 2 * effectiveWidth}, 0.0f);
    }
    if (BorderStyle.DOT_DOT_DASH.equals(edge.getBorderStyle()))
    {
      return new BasicStroke(effectiveWidth, BasicStroke.CAP_SQUARE,
          BasicStroke.JOIN_MITER,
          10.0f, new float[]{0, 2 * effectiveWidth,
              0, 2 * effectiveWidth,
              6 * effectiveWidth, 2 * effectiveWidth}, 0.0f);
    }
    return new BasicStroke(effectiveWidth, BasicStroke.CAP_BUTT, BasicStroke.JOIN_MITER);
  }
View Full Code Here


      if (staticBoxLayoutProperties.getBorderTop() > 0)
      {
        final BorderEdge borderEdge = border.getTop();

        final BasicStroke basicStroke = createStroke(borderEdge, staticBoxLayoutProperties.getBorderTop());
        if (basicStroke != null)
        {
          g2d.setColor(borderEdge.getColor());
          g2d.setStroke(basicStroke);
          g2d.draw(borderShape);
        }
      }
      g2d.setColor(oldColor);
      g2d.setStroke(oldStroke);
      return;
    }


    if (backgroundColor != null)
    {
      final Shape borderShape = getBorderShape();
      g2d.setColor(backgroundColor);
      g2d.fill(borderShape);
    }

    final StaticBoxLayoutProperties sblp = this.staticBoxLayoutProperties;
    if (sblp.getBorderTop() > 0)
    {
      final BorderEdge borderEdge = border.getTop();
      final BasicStroke basicStroke = createStroke(borderEdge, staticBoxLayoutProperties.getBorderTop());
      if (basicStroke != null)
      {
        g2d.setColor(borderEdge.getColor());
        g2d.setStroke(basicStroke);
        g2d.draw(getBorderTopShape());
      }
    }

    if (sblp.getBorderRight() > 0)
    {
      final BorderEdge borderEdge = border.getRight();
      final BasicStroke basicStroke = createStroke(borderEdge, staticBoxLayoutProperties.getBorderRight());
      if (basicStroke != null)
      {
        g2d.setColor(borderEdge.getColor());
        g2d.setStroke(basicStroke);
        g2d.draw(getBorderRightShape());
      }
    }

    if (sblp.getBorderBottom() > 0)
    {
      final BorderEdge borderEdge = border.getBottom();
      final BasicStroke basicStroke = createStroke(borderEdge, staticBoxLayoutProperties.getBorderBottom());
      if (basicStroke != null)
      {
        g2d.setColor(borderEdge.getColor());
        g2d.setStroke(basicStroke);
        g2d.draw(getBorderBottomShape());
      }
    }

    if (sblp.getBorderLeft() > 0)
    {
      final BorderEdge borderEdge = border.getLeft();
      final BasicStroke basicStroke = createStroke(borderEdge, staticBoxLayoutProperties.getBorderLeft());
      if (basicStroke != null)
      {
        g2d.setColor(borderEdge.getColor());
        g2d.setStroke(basicStroke);
        g2d.draw(getBorderLeftShape());
View Full Code Here

    final Shape s = getShape();
    g2.translate(x, y);
    g2.setPaint(Color.black);
    if (this.draw)
    {
      g2.setStroke(new BasicStroke(0.5f));
      g2.draw(s);
    }
    if (this.fill)
    {
      g2.fill(s);
View Full Code Here

        //      newbie.setGraphicID(egraphic.gID);
        newbie.setLineType(getOMGraphicLineType(egraphic.lType.value()));
        newbie.setRenderType(getOMGraphicRenderType(egraphic.rType.value()));
        //      newbie.setGraphicType(getOMGraphicType(egraphic.gType.value()));
        newbie.setStroke(new BasicStroke(egraphic.lineWidth));
        newbie.setDeclutterType(egraphic.dcType.value());
        newbie.setLinePaint(getColor(egraphic.color));
        newbie.setFillPaint(getColor(egraphic.fillColor));

        if (newbie instanceof JObjectHolder)
View Full Code Here

        case com.bbn.openmap.CSpecialist.GraphicPackage.settableFields._GF_fillColor:
            ((OMGraphic) graphic).setFillPaint(getColor(update.fillColor()));
            break;

        case com.bbn.openmap.CSpecialist.GraphicPackage.settableFields._GF_lineWidth:
            ((OMGraphic) graphic).setStroke(new BasicStroke(update.lineWidth()));
            break;

        case com.bbn.openmap.CSpecialist.GraphicPackage.settableFields._GF_stipple:
            System.err.println("ignoring stipple");
            //            ((OMGraphic)graphic).setStipple(getOMStipple(update.stipple()));
View Full Code Here

  protected void configureChart(final JFreeChart chart)
  {
    super.configureChart(chart);

    //Create the stroke for the primary (= real) data series...
    final Stroke thick = new BasicStroke(thicknessprimaryseries);

    //...and apply that stroke to the series
    final SpiderWebPlot webPlot = (SpiderWebPlot) chart.getPlot();

    if (StringUtils.isEmpty(getTooltipFormula()) == false)
View Full Code Here

    labelFactory.setMinimumSize(new FloatDimension(-100, 15));
    labelFactory.setText("Rating");
    b.addElement(labelFactory.createElement());

    b.addElement(HorizontalLineElementFactory.createHorizontalLine
        (15, null, new BasicStroke(1)));

    final Group group = report.getGroupByName("record-group");
    group.getHeader().addElement(b);
  }
View Full Code Here

    // use a watermark to draw a frame around the page...
    final Band watermarkBand = report.getWatermark();
    final RectangleElementFactory sef = new RectangleElementFactory();
    sef.setMinimumSize(new FloatDimension(-100.0f, -100));
    sef.setColor(Color.black);
    sef.setStroke(new BasicStroke(1.0f));
    sef.setShouldDraw(Boolean.TRUE);
    sef.setScale(Boolean.TRUE);
    sef.setKeepAspectRatio(Boolean.FALSE);
    watermarkBand.addElement(sef.createElement());
  }
View Full Code Here

  private PropertyChangeSupport propertyChangeSupport;

  public BasicStrokeEditor()
  {
    super();
    value = new BasicStroke();
    propertyChangeSupport = new PropertyChangeSupport(this);
  }
View Full Code Here

      if (v < 0)
      {
        setValue(BorderStyle.getBorderStyle(strings[0].trim()));
        return;
      }
      setValue(new BasicStroke(v));
      return;
    }
    if (strings.length > 2)
    {
      return;
View Full Code Here

TOP

Related Classes of java.awt.BasicStroke$BufferedPath

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.