Examples of arc()


Examples of com.google.gwt.canvas.dom.client.Context2d.arc()

         }
      }

      // draw a circle on the nexus
      ctx.beginPath();
      ctx.arc(nexusColumn * colWidth, height / 2.0,
              theme.getCircleRadius() + theme.getStrokeWidth(), 0, Math.PI * 2);
      ctx.closePath();
      ctx.fill();

      ctx.beginPath();
View Full Code Here

Examples of com.google.gwt.canvas.dom.client.Context2d.arc()

              theme.getCircleRadius() + theme.getStrokeWidth(), 0, Math.PI * 2);
      ctx.closePath();
      ctx.fill();

      ctx.beginPath();
      ctx.arc(nexusColumn * colWidth, height / 2.0,
              theme.getCircleRadius(), 0, Math.PI * 2);
      ctx.closePath();
      ctx.setFillStyle("white");
      ctx.fill();

View Full Code Here

Examples of com.google.gwt.canvas.dom.client.Context2d.arc()

  @Override
  public void draw(Surface surface) {
    Context2d context = surface.getContext();
    context.beginPath();
    context.arc(fCenter.x, fCenter.y, fRadius, 0, MathHelper.TWO_PI, true);
    context.closePath();
  }
}
View Full Code Here

Examples of com.google.gwt.canvas.dom.client.Context2d.arc()

  public void visit(Surface surface) {
    Context2d context = surface.getContext();
    context.save();
    context.translate(x + width / 2, y + height / 2);
    context.scale(width / 2, height / 2);
    context.arc(0, 0, 1, 0, MathHelper.TWO_PI, true);
    context.restore();
  }
}
View Full Code Here

Examples of com.google.gwt.canvas.dom.client.Context2d.arc()

  }
 
  @Override
  public void visit(Surface surface) {
    Context2d context = surface.getContext();
    context.arc(x, y, radius, 0, MathHelper.TWO_PI, true);
  }
}
View Full Code Here

Examples of com.google.gwt.canvas.dom.client.Context2d.arc()

      double weight = slice.weight / totalWeight;
      double endAngle = startAngle + (weight * RADIANS_IN_CIRCLE);
      context.setFillStyle(slice.fill);
      context.beginPath();
      context.moveTo(cx, cy);
      context.arc(cx, cy, radius, startAngle, endAngle);
      context.fill();
      startAngle = endAngle;
    }
  }

View Full Code Here

Examples of com.google.gwt.canvas.dom.client.Context2d.arc()

            for (Fixture fixture = body.getFixtureList(); fixture != null; fixture = fixture.getNext()) {
                Shape shape = fixture.getShape();
                if (shape.getType() == ShapeType.CIRCLE) {
                    CircleShape circle = (CircleShape)shape;
                    context.beginPath();
                    context.arc(circle.m_p.x, circle.m_p.y, circle.getRadius(), 0, Math.PI * 2, true);
                    context.closePath();
                    context.stroke();
                } else if (shape.getType() == ShapeType.POLYGON) {
                    PolygonShape poly = (PolygonShape)shape;
                    Vec2[] vertices = poly.getVertices();
View Full Code Here

Examples of com.google.gwt.canvas.dom.client.Context2d.arc()

    @Override
    public void draw( final Canvas canvas ) {
        final Context2d context = canvas.getContext2d();
        context.setFillStyle( CssColor.make( 200, 100, 50 ) );
        context.beginPath();
        context.arc( c.getX(),
                     c.getY(),
                     NODE_RADIUS,
                     0,
                     Math.PI * 2.0,
                     true );
View Full Code Here

Examples of com.google.gwt.canvas.dom.client.Context2d.arc()

    @Override
    public void draw( final Canvas canvas ) {
        final Context2d context = canvas.getContext2d();
        context.setFillStyle( CssColor.make( 60, 200, 126 ) );
        context.beginPath();
        context.arc( c.getX(),
                     c.getY(),
                     NODE_RADIUS,
                     0,
                     Math.PI * 2.0,
                     true );
View Full Code Here

Examples of com.lowagie.text.pdf.PdfTemplate.arc()

            PdfTemplate template = cb.createTemplate(500, 200);
            template.setLineWidth(2f);
            template.rectangle(2.5f, 2.5f, 495f, 195f);
            template.stroke();
            template.setLineWidth(12f);
            template.arc(40f - (float) Math.sqrt(12800), 120f + (float) Math.sqrt(12800), 200f - (float) Math.sqrt(12800), -40f + (float) Math.sqrt(12800), 281.25f, 33.75f);
            template.arc(40f, 120f, 200f, -40f, 90f, 45f);
            template.stroke();
            template.setLineCap(1);
            template.setLineWidth(12f);
            template.arc(80f, 40f, 160f, 120f, 90f, 180f);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.