protected virtual void DrawHeart(Canvas canvas, float x, float y, float width, float height, float cornerRadius, Paint fillPaint, Paint strokePaint) { var length = Math.Min(height, width); var p1 = new PointF(x, y + length); var p2 = new PointF(x + 2f * length / 3f, y + length); var p3 = new PointF(x + 2f * length / 3f, y + length / 3f); var p4 = new PointF(x, y + length / 3f); var radius = length / 3f; var path = new Path(); path.MoveTo(p4.X, p4.Y); path.LineTo(p1.X, p1.Y - cornerRadius); path.LineTo(p1.X + cornerRadius, p1.Y); path.LineTo(p2.X, p2.Y); path.LineTo(p3.X, p3.Y); path.Close(); if (cornerRadius > 0) { path.AddArc(new RectF(p1.X, (p1.Y + p4.Y) / 2f, (p2.X + p1.X) / 2f, p2.Y), 90, 90); } path.AddArc(new RectF(p3.X - radius, p3.Y, p3.X + radius, p2.Y), -90f, 180f); path.AddArc(new RectF(p4.X, p4.Y - radius, p3.X, p4.Y + radius), 180f, 180f); var matrix = new Matrix(); matrix.SetTranslate(-length / 3f, -length * 2f / 3f); path.Transform(matrix); matrix.Reset(); matrix.SetRotate(-45f); path.Transform(matrix); matrix.Reset(); matrix.SetScale(0.85f, 0.85f); path.Transform(matrix); matrix.Reset(); matrix.SetTranslate(width / 2f, 1.1f * height / 2f); path.Transform(matrix); this.DrawPath(canvas, path, fillPaint, strokePaint); }
public void Rescale(MotoRect motoRect) { //int imageWidth = 360; //int moonWidth = 200; //int scaledMoonWidth = motoRect.Width * moonWidth / imageWidth; //int leftMargin = (motoRect.Width - scaledMoonWidth) / 2; //int unit = leftMargin / 7; int unit = Scale.Unit(motoRect); int margin = 3; // リスト for (int i = 0; i < 6; i++) { //listRects[i].Left = unit * 13; //listRects[i].Top = ((unit * 10) + i * (int)(unit * 2.4f)); //listRects[i].Right = listRects[i].Left + unit * 12; //listRects[i].Bottom = listRects[i].Top + unit * 2; listRects[i] = new Rect( unit * 13, (unit * 10) + i * (int)(unit * 2.4f), unit * 13 + unit * 12, ((unit * 10) + i * (int)(unit * 2.4f)) + unit * 2); } listTextPaint.TextSize = (float)unit * 2f * 0.9f; float textWidth = listTextPaint.MeasureText("00:00"); dateLeft = unit * 7; timeLeft = listRects[0].CenterX() - (int)(textWidth / 2f); // スケール scaleRectF = new RectF(unit * 3, unit * 3, motoRect.Right - unit * 3, motoRect.Bottom - unit * 3); scalePath.AddArc(scaleRectF, scaleStartAngle, scaleSweepAngle); scalePaint.StrokeWidth = unit * 2; // テキスト scaleTextRectF = new RectF(unit * 4 - margin, unit * 4 - margin, motoRect.Right - unit * 4 + margin, motoRect.Bottom - unit * 4 + margin); scaleTextPaint.TextSize = listTextPaint.TextSize; float textSweep = 360.0f * textWidth / ((float)Math.PI * scaleTextRectF.Width()); //360.0f * textWidth / (2.0f * (float)Math.PI * scaleTextRectF.Width()); float textStart = scaleStartAngle + (scaleSweepAngle / 2) - textSweep / 2; scaleTextPath.AddArc(scaleTextRectF, textStart, textSweep); // リマインダ reminderRectF = new RectF(unit * 4.5f, unit * 4.5f, motoRect.Right - unit * 4.5f, motoRect.Bottom - unit * 4.5f); reminderPaint.StrokeWidth = unit; }
protected override void UpdatePath() { RGFloat min = Math.Min(Width, Height); RGFloat c = roundRate * min; #if WINFORM Path.Reset(); if (c > 0) { Path.AddArc(0, 0, c, c, 180, 90); Path.AddArc(Width - c - 1, 0, c, c, 270, 90); Path.AddArc(Width - c - 1, Height - c, c, c, 0, 90); Path.AddArc(0, Height - c, c, c, 90, 90); Path.CloseAllFigures(); } else { Path.AddRectangle(new System.Drawing.RectangleF(0, 0, Width, Height)); } #elif WPF Path.Clear(); if (c > 0) { Path.AddGeometry(new System.Windows.Media.RectangleGeometry(new System.Windows.Rect(0, 0, Width, Height)) { RadiusX = c, RadiusY = c }); } #elif ANDROID #endif // WINFORM }
/// <override></override> protected override bool CalculatePath() { if (base.CalculatePath()) { int r = CalcCornerRadius(); int left = (int)Math.Round(-Width / 2f); int top = (int)Math.Round(-Height / 2f); int right = left + Width; int bottom = top + Height; Path.Reset(); Path.StartFigure(); Path.AddLine(left + r, top, right - r, top); Path.AddArc(right - r - r, top, r + r, r + r, -90, 90); Path.AddLine(right, top + r, right, bottom - r); Path.AddArc(right - r - r, bottom - r - r, r + r, r + r, 0, 90); Path.AddLine(right - r, bottom, left + r, bottom); Path.AddArc(left, bottom - r - r, r + r, r + r, 90, 90); Path.AddLine(left, bottom - r, left, top + r); Path.AddArc(left, top, r + r, r + r, 180, 90); Path.CloseFigure(); return(true); } else { return(false); } }
public override void AddArc <TRectangle>(TRectangle arc, Single startAngle, Single endAngle) { Path.AddArc(I4(arc.X), I4(arc.Y), I4(arc.Width), I4(arc.Height), startAngle, endAngle); }
private void BNCPath() { WidthF = 11.91F; HeightF = 9.91F; Path.AddPolygon(new PointF[] { new PointF(-4.905F * Scale * _pixelToMmMultiple, -4.905F * -1 * Scale * _pixelToMmMultiple), new PointF(-4.905F * Scale * _pixelToMmMultiple, -0.5F * -1 * Scale * _pixelToMmMultiple), new PointF(-5.905F * Scale * _pixelToMmMultiple, -0.5F * -1 * Scale * _pixelToMmMultiple), new PointF(-5.905F * Scale * _pixelToMmMultiple, 0.5F * -1 * Scale * _pixelToMmMultiple), new PointF(-4.905F * Scale * _pixelToMmMultiple, 0.5F * -1 * Scale * _pixelToMmMultiple), new PointF(-4.905F * Scale * _pixelToMmMultiple, 4.905F * -1 * Scale * _pixelToMmMultiple), new PointF(4.905F * Scale * _pixelToMmMultiple, 4.905F * -1 * Scale * _pixelToMmMultiple), new PointF(4.905F * Scale * _pixelToMmMultiple, 0.5F * -1 * Scale * _pixelToMmMultiple), new PointF(5.905F * Scale * _pixelToMmMultiple, 0.5F * -1 * Scale * _pixelToMmMultiple), new PointF(5.905F * Scale * _pixelToMmMultiple, -0.5F * -1 * Scale * _pixelToMmMultiple), new PointF(4.905F * Scale * _pixelToMmMultiple, -0.5F * -1 * Scale * _pixelToMmMultiple), new PointF(4.905F * Scale * _pixelToMmMultiple, -4.905F * -1 * Scale * _pixelToMmMultiple) }); Path.AddArc(-4.905F * Scale * _pixelToMmMultiple, 4.905F * -1 * Scale * _pixelToMmMultiple, 9.81F * Scale * _pixelToMmMultiple, 9.81F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-4.905F * Scale * _pixelToMmMultiple, 4.905F * -1 * Scale * _pixelToMmMultiple, 9.81F * Scale * _pixelToMmMultiple, 9.81F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-4.05F * Scale * _pixelToMmMultiple, 4.05F * -1 * Scale * _pixelToMmMultiple, 8.1F * Scale * _pixelToMmMultiple, 8.1F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-4.05F * Scale * _pixelToMmMultiple, 4.05F * -1 * Scale * _pixelToMmMultiple, 8.1F * Scale * _pixelToMmMultiple, 8.1F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-2.415F * Scale * _pixelToMmMultiple, 2.415F * -1 * Scale * _pixelToMmMultiple, 4.83F * Scale * _pixelToMmMultiple, 4.83F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-2.415F * Scale * _pixelToMmMultiple, 2.415F * -1 * Scale * _pixelToMmMultiple, 4.83F * Scale * _pixelToMmMultiple, 4.83F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-0.66F * Scale * _pixelToMmMultiple, 0.66F * -1 * Scale * _pixelToMmMultiple, 1.32F * Scale * _pixelToMmMultiple, 1.32F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-0.66F * Scale * _pixelToMmMultiple, 0.66F * -1 * Scale * _pixelToMmMultiple, 1.32F * Scale * _pixelToMmMultiple, 1.32F * Scale * _pixelToMmMultiple, 180F, 360F); }
protected override void UpdatePath() { var clientRect = this.ClientBounds; #if WINFORM Path.Reset(); if (sweepAngle > 0 && clientRect.Width > 0 && clientRect.Height > 0) { Path.AddLine(this.OriginPoint, this.OriginPoint); Path.AddArc(0, 0, clientRect.Width, clientRect.Height, this.startAngle - 90, this.sweepAngle); Path.CloseAllFigures(); } #elif WPF Path.Clear(); if (this.sweepAngle > 0) { System.Windows.Media.PathFigure pf = new System.Windows.Media.PathFigure(); pf.Segments.Add(new System.Windows.Media.LineSegment(this.OriginPoint, false)); pf.Segments.Add(new System.Windows.Media.ArcSegment(new System.Windows.Point(0, 0), new System.Windows.Size(this.Width, this.Height), this.sweepAngle, true, System.Windows.Media.SweepDirection.Clockwise, false)); Path.Figures.Add(pf); } #elif ANDROID #endif // WINFORM }
protected override void Setup() { base.Setup(); if (Instance == null) { Instance = this; } this.KeyPress += PongPaddleView_KeyPress; int shapeSize = Math.Min(this.Width, this.Height); int shapeSizeThird = shapeSize / 3; int strokeWidth = 10; int strokeWidthHalf = strokeWidth / 2; // setup details on paint used for arc _paintArc.SetStyle(Paint.Style.Stroke); _paintArc.StrokeWidth = strokeWidth; // setup details on paint used for rect _paintRect.SetStyle(Paint.Style.Fill); // setup details on paint used for rect _paintDebug.SetStyle(Paint.Style.Stroke); Path pathArc = new Path(); // add the arc slightly smaller then the drawable size will be to prevent clipping pathArc.AddArc(0, 0, shapeSize - strokeWidthHalf, shapeSize - strokeWidthHalf, 75, 30); _drawableArc.Shape = new PathShape(pathArc, shapeSize, shapeSize); _drawableArc.Paint.Set(_paintArc); // set collision bounds pathArc.ComputeBounds(CollisionBounds, true); CollisionBounds.Inset(-strokeWidthHalf, -strokeWidthHalf); RectF arcBounds = new RectF(); pathArc.ComputeBounds(arcBounds, true); arcBounds.Top -= strokeWidthHalf; arcBounds.Bottom -= strokeWidthHalf; Path pathRect = new Path(); pathRect.AddRect(arcBounds, Path.Direction.Cw); _drawableRect.Shape = new PathShape(pathRect, shapeSize, shapeSize); _drawableRect.Paint.Set(_paintRect); // setup debug drawable pathArc.ComputeBounds(arcBounds, true); arcBounds.Inset(-strokeWidthHalf, -strokeWidthHalf); arcBounds.Bottom -= strokeWidthHalf; Path pathDebug = new Path(); pathDebug.AddRect(arcBounds, Path.Direction.Cw); _drawableDebug.Shape = new PathShape(pathDebug, shapeSize, shapeSize); _drawableDebug.Paint.Set(_paintDebug); }
private void initPath() { Path mPath = new Path(); RectF rectF = new RectF(mWidth / 2f - dip2px(1.5f), mHeight / 2f - dip2px(1.5f) , mWidth / 2f + dip2px(1.5f), mHeight / 2f + dip2px(1.5f)); mPath.AddArc(rectF, 180f, 180f); rectF.Set(rectF.Left - dip2px(3), rectF.Top - dip2px(1.5f), rectF.Right, rectF.Bottom + dip2px(1.5f)); mPath.AddArc(rectF, 0f, 180f); rectF.Set(rectF.Left, rectF.Top - dip2px(1.5f), rectF.Right + dip2px(3), rectF.Bottom + dip2px(1.5f)); mPath.AddArc(rectF, 180f, 180f); rectF.Set(rectF.Left - dip2px(3), rectF.Top - dip2px(1.5f), rectF.Right, rectF.Bottom + dip2px(1.5f)); mPath.AddArc(rectF, 0f, 180f); eye = Bitmap.CreateBitmap((int)mWidth, (int)mHeight, Bitmap.Config.Argb8888); Canvas c = new Canvas(eye); mPaint.StrokeWidth = dip2px(1.7f); c.DrawPath(mPath, mPaint); }
/// <summary> /// 向拼图碎片的路径中添加一条边,路径的当前节点总是在起始点。 /// </summary> /// <param name="path">路径。</param> /// <param name="startPoint">边的起始点。</param> /// <param name="endPoint">边的结束点。</param> /// <param name="randoms">该边的凹凸性。</param> /// <param name="border">与该条边相关的一组随机数,范围都是 [0, 1)。</param> protected override void AddBorder(Path path, Vector2 startPoint, Vector2 endPoint, bool border, float[] randoms) { Vector2 sp = Vector2.Lerp(startPoint, endPoint, 1f / 3); Vector2 ep = Vector2.Lerp(startPoint, endPoint, 2f / 3); path.AddLine(sp); double angle = Math.Atan2(endPoint.Y - startPoint.Y, endPoint.X - startPoint.X) * 180 / Math.PI + 180; float len = Vector2.Distance(startPoint, endPoint) / 6; path.AddArc(ep, new Size2F(len, len), (float)angle, border ? SweepDirection.CounterClockwise : SweepDirection.Clockwise, ArcSize.Small); path.AddLine(endPoint); }
private void RF_N_PlugPath() { WidthF = 17F; HeightF = 17F; Path.AddArc(-8.5F * Scale * _pixelToMmMultiple, 8.5F * -1 * Scale * _pixelToMmMultiple, 17F * Scale * _pixelToMmMultiple, 17F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-8F * Scale * _pixelToMmMultiple, 8F * -1 * Scale * _pixelToMmMultiple, 16F * Scale * _pixelToMmMultiple, 16F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-8F * Scale * _pixelToMmMultiple, 8F * -1 * Scale * _pixelToMmMultiple, 16F * Scale * _pixelToMmMultiple, 16F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-4.69F * Scale * _pixelToMmMultiple, 4.69F * -1 * Scale * _pixelToMmMultiple, 9.38F * Scale * _pixelToMmMultiple, 9.38F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-4.19F * Scale * _pixelToMmMultiple, 4.19F * -1 * Scale * _pixelToMmMultiple, 8.38F * Scale * _pixelToMmMultiple, 8.38F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-4.19F * Scale * _pixelToMmMultiple, 4.19F * -1 * Scale * _pixelToMmMultiple, 8.38F * Scale * _pixelToMmMultiple, 8.38F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-0.8F * Scale * _pixelToMmMultiple, 0.8F * -1 * Scale * _pixelToMmMultiple, 1.6F * Scale * _pixelToMmMultiple, 1.6F * Scale * _pixelToMmMultiple, 180F, 360F); }
public Path GetPath() { var diameterX = Corners.Radius.Width * 2; var diameterY = Corners.Radius.Height * 2; var size = new SizeF(diameterX, diameterY); var path = new Path(true); if (Image != null) { path = path.AddImage(Image, Rectangle); } path = Corners.RoundedCorners.Contains(Corner.TopLeft) ? path.AddArc(Rectangle.Location, size, 180, 90) : path.AddPoint(Rectangle.Location); if (Cutout) { path = path.AddArc( Rectangle.Left + Rectangle.Width / 2 - Corners.Radius.Width, Rectangle.Top - Corners.Radius.Height, diameterX, diameterY, 180, -180); } path = Corners.RoundedCorners.Contains(Corner.TopRight) ? path.AddArc( Rectangle.Right - diameterX, Rectangle.Top, diameterX, diameterY, 270, 90) : path.AddPoint(Rectangle.Right, Rectangle.Top); path = Corners.RoundedCorners.Contains(Corner.BottomRight) ? path.AddArc(Rectangle.Right - diameterX, Rectangle.Bottom - diameterY, diameterX, diameterY, 0, 90) : path.AddPoint(Rectangle.Right, Rectangle.Bottom); path = Corners.RoundedCorners.Contains(Corner.BottomLeft) ? path.AddArc(Rectangle.Left, Rectangle.Bottom - diameterY, diameterX, diameterY, 90, 90) : path.AddPoint(Rectangle.Left, Rectangle.Bottom); return(path); }
protected override void UpdatePath() { var clientRect = this.ClientBounds; Path.Reset(); if (sweepAngle > 0 && clientRect.Width > 0 && clientRect.Height > 0) { Path.AddLine(this.OriginPoint, this.OriginPoint); Path.AddArc(0, 0, clientRect.Width, clientRect.Height, this.startAngle - 90, this.sweepAngle); Path.CloseAllFigures(); } }
public Path BuildPath(float animationProgress, float animationSeek) { Path path = null; if (base.Value.StartAngle <= animationSeek) { path = new Path(); var sweepAngle = CalculateSweepAngle(animationSeek, base.Value); path.AddArc(base.DrawingArea, base.Value.StartAngle, sweepAngle); } return(path); }
protected override void OnDraw(Canvas canvas) { var rect = new RectF(0, 0, canvas.Width, canvas.Height); var path = new Path(); path.MoveTo(rect.CenterX(), rect.CenterY()); path.AddArc(rect, _startAngle, _endAngle - _startAngle); path.LineTo(rect.CenterX(), rect.CenterY()); path.Close(); canvas.ClipPath(path); base.OnDraw(canvas); }
public override void AddArc <TRectangle>(TRectangle arc, Single startAngle, Single endAngle) { Path.AddArc(R4(arc.Left), R4(arc.Top), R4(arc.Right), R4(arc.Bottom), startAngle, endAngle); _pointTypes.AddRange(new[] { PathPointType.Bezier3, PathPointType.Bezier3, PathPointType.Bezier3 }); }
protected override void OnDraw(Canvas canvas) { base.OnDraw(canvas); canvas.DrawCircle(_centerX, _centerY, _radius, _circlePaint); var path = new Path(); path.AddArc(_rectangle, _startAngle, _endAngle - _startAngle); path.LineTo(_centerX, _centerY); canvas.DrawPath(path, _arcPaint); //canvas.DrawArc(_rectangle, _startAngle, _endAngle - _startAngle, false, _arcPaint); }
private void RF_TNC_PlugPath() { WidthF = 13F; HeightF = 13F; Path.AddArc(-6.5F * Scale * _pixelToMmMultiple, 6.5F * -1 * Scale * _pixelToMmMultiple, 13F * Scale * _pixelToMmMultiple, 13F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-5.59F * Scale * _pixelToMmMultiple, 5.59F * -1 * Scale * _pixelToMmMultiple, 11.18F * Scale * _pixelToMmMultiple, 11.18F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-5.59F * Scale * _pixelToMmMultiple, 5.59F * -1 * Scale * _pixelToMmMultiple, 11.18F * Scale * _pixelToMmMultiple, 11.18F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-4.03F * Scale * _pixelToMmMultiple, 4.03F * -1 * Scale * _pixelToMmMultiple, 8.06F * Scale * _pixelToMmMultiple, 8.06F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-4.03F * Scale * _pixelToMmMultiple, 4.03F * -1 * Scale * _pixelToMmMultiple, 8.06F * Scale * _pixelToMmMultiple, 8.06F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-4.03F * Scale * _pixelToMmMultiple, 4.03F * -1 * Scale * _pixelToMmMultiple, 8.06F * Scale * _pixelToMmMultiple, 8.06F * Scale * _pixelToMmMultiple, 180F, 0F); Path.AddArc(-2.415F * Scale * _pixelToMmMultiple, 2.415F * -1 * Scale * _pixelToMmMultiple, 4.93F * Scale * _pixelToMmMultiple, 4.93F * Scale * _pixelToMmMultiple, 180F, 0F); Path.AddArc(-2.415F * Scale * _pixelToMmMultiple, 2.415F * -1 * Scale * _pixelToMmMultiple, 4.83F * Scale * _pixelToMmMultiple, 4.83F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-0.66F * Scale * _pixelToMmMultiple, 0.66F * -1 * Scale * _pixelToMmMultiple, 1.32F * Scale * _pixelToMmMultiple, 1.32F * Scale * _pixelToMmMultiple, 180F, 360F); }
public Path BuildPath(float animationProgress, float animationSeek) { var startAngle = FitChart.StartAngle; var valueSweepAngle = base.Value.StartAngle + base.Value.SweepAngle; valueSweepAngle -= startAngle; var sweepAngle = valueSweepAngle * animationProgress; var path = new Path(); path.AddArc(base.DrawingArea, startAngle, sweepAngle); return(path); }
private void FCPath() { WidthF = 9.8F; HeightF = 9.8F; Path.AddArc(-4.9F * Scale * _pixelToMmMultiple, 4.9F * -1 * Scale * _pixelToMmMultiple, 9.8F * Scale * _pixelToMmMultiple, 9.8F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-4.85F * Scale * _pixelToMmMultiple, 4.85F * -1 * Scale * _pixelToMmMultiple, 9.7F * Scale * _pixelToMmMultiple, 9.7F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-4.85F * Scale * _pixelToMmMultiple, 4.85F * -1 * Scale * _pixelToMmMultiple, 9.7F * Scale * _pixelToMmMultiple, 9.7F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-4.45F * Scale * _pixelToMmMultiple, 4.45F * -1 * Scale * _pixelToMmMultiple, 8.9F * Scale * _pixelToMmMultiple, 8.9F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-4.45F * Scale * _pixelToMmMultiple, 4.45F * -1 * Scale * _pixelToMmMultiple, 8.9F * Scale * _pixelToMmMultiple, 8.9F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-3F * Scale * _pixelToMmMultiple, 3F * -1 * Scale * _pixelToMmMultiple, 6F * Scale * _pixelToMmMultiple, 6F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-3F * Scale * _pixelToMmMultiple, 3F * -1 * Scale * _pixelToMmMultiple, 6F * Scale * _pixelToMmMultiple, 6F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-1.2495F * Scale * _pixelToMmMultiple, 1.2495F * -1 * Scale * _pixelToMmMultiple, 2.499F * Scale * _pixelToMmMultiple, 2.499F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-1.2495F * Scale * _pixelToMmMultiple, 1.2495F * -1 * Scale * _pixelToMmMultiple, 2.499F * Scale * _pixelToMmMultiple, 2.499F * Scale * _pixelToMmMultiple, 180F, 360F); }
public void AddArc(RectangleF rectangle, float startAngle, float sweepAngle) { _bounds = null; Path.AddArc((RectangleF)rectangle, startAngle, sweepAngle); _points.Add(new PointF(rectangle.Location.X, rectangle.Location.Y)); _pathTypes.Add(1); // start point of line _points.Add(new PointF(rectangle.Location.X + rectangle.Width, rectangle.Location.Y)); _pathTypes.Add(0x20); // TODO LX: ??? _points.Add(new PointF(rectangle.Location.X, rectangle.Location.Y + rectangle.Height)); _pathTypes.Add(0x20); // TODO LX: ??? _points.Add(new PointF(rectangle.Location.X + rectangle.Width, rectangle.Location.Y + rectangle.Height)); _pathTypes.Add(1); // end point of line }
protected override void UpdatePath() { var clientRect = this.ClientBounds; RGFloat s = Math.Min(this.arcWidth, Math.Min(clientRect.Width - 1, clientRect.Height - 1)); Path.Reset(); if (this.SweepAngle > 0 && clientRect.Width > 0 && clientRect.Height > 0) { var startAngle = this.StartAngle - 90; Path.AddArc(0, 0, clientRect.Width, clientRect.Height, startAngle, this.SweepAngle); Path.AddArc(s / 2, s / 2, clientRect.Width - s, clientRect.Height - s, startAngle + this.SweepAngle, -this.SweepAngle); Path.CloseAllFigures(); } }
private void RJ21Path() { WidthF = 82.6F; HeightF = 15F; Path.AddArc(-41.3F * Scale * _pixelToMmMultiple, 2F * -1 * Scale * _pixelToMmMultiple, 4F * Scale * _pixelToMmMultiple, 4F * Scale * _pixelToMmMultiple, 145F, 70F); Path.AddLines(new PointF[] { new PointF(-35F * Scale * _pixelToMmMultiple, 7.5F * -1 * Scale * _pixelToMmMultiple), new PointF(35F * Scale * _pixelToMmMultiple, 7.5F * -1 * Scale * _pixelToMmMultiple) }); Path.AddArc(37.3F * Scale * _pixelToMmMultiple, 2F * -1 * Scale * _pixelToMmMultiple, 4F * Scale * _pixelToMmMultiple, 4F * Scale * _pixelToMmMultiple, 305F, 70F); Path.AddLines(new PointF[] { new PointF(35F * Scale * _pixelToMmMultiple, -7.5F * -1 * Scale * _pixelToMmMultiple), new PointF(-35F * Scale * _pixelToMmMultiple, -7.5F * -1 * Scale * _pixelToMmMultiple) }); Path.CloseFigure(); Path.AddArc(-40F * Scale * _pixelToMmMultiple, 1.1F * -1 * Scale * _pixelToMmMultiple, 2.2F * Scale * _pixelToMmMultiple, 2.2F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(37.8F * Scale * _pixelToMmMultiple, 1.1F * -1 * Scale * _pixelToMmMultiple, 2.2F * Scale * _pixelToMmMultiple, 2.2F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-32.32F * Scale * _pixelToMmMultiple, 6.125F * -1 * Scale * _pixelToMmMultiple, 4F * Scale * _pixelToMmMultiple, 4F * Scale * _pixelToMmMultiple, 180F, 90F); Path.AddArc(28.32F * Scale * _pixelToMmMultiple, 6.125F * -1 * Scale * _pixelToMmMultiple, 4F * Scale * _pixelToMmMultiple, 4F * Scale * _pixelToMmMultiple, 270F, 90F); Path.AddArc(26.32F * Scale * _pixelToMmMultiple, -2.125F * -1 * Scale * _pixelToMmMultiple, 4F * Scale * _pixelToMmMultiple, 4F * Scale * _pixelToMmMultiple, 10F, 90F); Path.AddArc(-30.32F * Scale * _pixelToMmMultiple, -2.125F * -1 * Scale * _pixelToMmMultiple, 4F * Scale * _pixelToMmMultiple, 4F * Scale * _pixelToMmMultiple, 80F, 90F); Path.CloseFigure(); Path.AddRectangle(new RectangleF(-25.92F * Scale * _pixelToMmMultiple, 1F * -1 * Scale * _pixelToMmMultiple, 51.84F * Scale * _pixelToMmMultiple, 2F * Scale * _pixelToMmMultiple)); }
private void RF_SMA_PlugPath() { WidthF = 8F; HeightF = 7F; Path.AddPolygon(new PointF[] { new PointF(4F * Scale * _pixelToMmMultiple, 0F * -1 * Scale * _pixelToMmMultiple), new PointF(2F * Scale * _pixelToMmMultiple, 3.464102F * -1 * Scale * _pixelToMmMultiple), new PointF(-2F * Scale * _pixelToMmMultiple, 3.464102F * -1 * Scale * _pixelToMmMultiple), new PointF(-4F * Scale * _pixelToMmMultiple, 4.90059E-16F * -1 * Scale * _pixelToMmMultiple), new PointF(-2F * Scale * _pixelToMmMultiple, -3.464102F * -1 * Scale * _pixelToMmMultiple), new PointF(2F * Scale * _pixelToMmMultiple, -3.464102F * -1 * Scale * _pixelToMmMultiple) }); Path.AddArc(-3.5F * Scale * _pixelToMmMultiple, 3.5F * -1 * Scale * _pixelToMmMultiple, 7F * Scale * _pixelToMmMultiple, 7F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-3.265F * Scale * _pixelToMmMultiple, 3.265F * -1 * Scale * _pixelToMmMultiple, 6.53F * Scale * _pixelToMmMultiple, 6.53F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-3.265F * Scale * _pixelToMmMultiple, 3.265F * -1 * Scale * _pixelToMmMultiple, 6.53F * Scale * _pixelToMmMultiple, 6.53F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-0.0255F * Scale * _pixelToMmMultiple, 0.0255F * -1 * Scale * _pixelToMmMultiple, 0.051F * Scale * _pixelToMmMultiple, 0.051F * Scale * _pixelToMmMultiple, 180F, 360F); }
public ResizeRotateHandler(Size size, Point location) { this.Rectangles = new List <Rectangle>(); Rectangles.Add(new Rectangle(location.X - 6, location.Y - 6, 6, 6)); Rectangles.Add(new Rectangle(size.Width + location.X, location.Y - 6, 6, 6)); Rectangles.Add(new Rectangle(size.Width + location.X, size.Height + location.Y, 6, 6)); Rectangles.Add(new Rectangle(location.X - 6, size.Height + location.Y, 6, 6)); Rectangles.Add(new Rectangle(size.Width + location.X - size.Width / 2 - 3, location.Y - 6, 6, 6)); Rectangles.Add(new Rectangle(size.Width + location.X, size.Height + location.Y - size.Height / 2 - 3, 6, 6)); Rectangles.Add(new Rectangle(size.Width + location.X - size.Width / 2 - 5, size.Height + location.Y, 6, 6)); Rectangles.Add(new Rectangle(location.X - 6, size.Height + location.Y - size.Height / 2 - 3, 6, 6)); this.Path = new GraphicsPath(); Path.AddArc(size.Width + location.X + 6, location.Y - 12, 6, 6, 185, 275); Path.AddLine(size.Width + location.X + 9, location.Y - 6, size.Width + location.X + 14, location.Y - 6); Path.AddLine(size.Width + location.X + 9, location.Y - 6, size.Width + location.X + 9, location.Y - 10); }
void DrawScale(Canvas canvas, MotoRect rect) { //if (MoonAge == MoonAges.Full & FaceStyle == FaceStyles.Moon) if (MoonAge == MoonAges.Full) { return; } canvas.DrawPath(scalePath, scalePaint); #region graph gray mm = 46~59 int minute = NextFullMoon.Minute; if (minute >= 46) { scaleGrayPath.Reset(); float startAngle = scaleStartAngle + (55 - minute) * 6; if (startAngle < scaleStartAngle) { startAngle = scaleStartAngle; } float sweepAngle = 30; if (minute <= 49) { sweepAngle = (minute - 45) * 6; } else if (minute >= 56) { sweepAngle = (60 - minute) * 6; } scaleGrayPath.AddArc(scaleRectF, startAngle, sweepAngle); canvas.DrawPath(scaleGrayPath, scaleGrayPaint); } #endregion canvas.DrawTextOnPath( NextFullMoon.ToString(FORMAT_HHMM, ci), scaleTextPath, 0, 0, scaleTextPaint); }
private void MUPath() { WidthF = 6.6F; HeightF = 4.4F; Path.AddPolygon(new PointF[] { new PointF(-3.3F * Scale * _pixelToMmMultiple, -2.2F * -1 * Scale * _pixelToMmMultiple), new PointF(-3.3F * Scale * _pixelToMmMultiple, 1.75F * -1 * Scale * _pixelToMmMultiple), new PointF(-2.3F * Scale * _pixelToMmMultiple, 1.75F * -1 * Scale * _pixelToMmMultiple), new PointF(-1.8F * Scale * _pixelToMmMultiple, 2.2F * -1 * Scale * _pixelToMmMultiple), new PointF(1.8F * Scale * _pixelToMmMultiple, 2.2F * -1 * Scale * _pixelToMmMultiple), new PointF(2.3F * Scale * _pixelToMmMultiple, 1.75F * -1 * Scale * _pixelToMmMultiple), new PointF(3.3F * Scale * _pixelToMmMultiple, 1.75F * -1 * Scale * _pixelToMmMultiple), new PointF(3.3F * Scale * _pixelToMmMultiple, -2.2F * -1 * Scale * _pixelToMmMultiple), new PointF(-2.7F * Scale * _pixelToMmMultiple, -2.2F * -1 * Scale * _pixelToMmMultiple) }); Path.AddRectangle(new RectangleF(-3.3F * Scale * _pixelToMmMultiple, 0.8F * -1 * Scale * _pixelToMmMultiple, 0.8F * Scale * _pixelToMmMultiple, 1.6F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(2.5F * Scale * _pixelToMmMultiple, 0.8F * -1 * Scale * _pixelToMmMultiple, 0.8F * Scale * _pixelToMmMultiple, 1.6F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(2.5F * Scale * _pixelToMmMultiple, 0.75F * -1 * Scale * _pixelToMmMultiple, 0.095F * Scale * _pixelToMmMultiple, 1.5F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(-2.6F * Scale * _pixelToMmMultiple, 0.75F * -1 * Scale * _pixelToMmMultiple, 0.095F * Scale * _pixelToMmMultiple, 1.5F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(2.7F * Scale * _pixelToMmMultiple, 1.75F * -1 * Scale * _pixelToMmMultiple, 0.6F * Scale * _pixelToMmMultiple, 0.45F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(-3.3F * Scale * _pixelToMmMultiple, 1.75F * -1 * Scale * _pixelToMmMultiple, 0.6F * Scale * _pixelToMmMultiple, 0.45F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(-3.3F * Scale * _pixelToMmMultiple, -1.3F * -1 * Scale * _pixelToMmMultiple, 0.6F * Scale * _pixelToMmMultiple, 0.9F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(2.7F * Scale * _pixelToMmMultiple, -1.3F * -1 * Scale * _pixelToMmMultiple, 0.6F * Scale * _pixelToMmMultiple, 0.9F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(-3.3F * Scale * _pixelToMmMultiple, 1.3F * -1 * Scale * _pixelToMmMultiple, 0.8F * Scale * _pixelToMmMultiple, 0.5F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(2.5F * Scale * _pixelToMmMultiple, 1.3F * -1 * Scale * _pixelToMmMultiple, 0.8F * Scale * _pixelToMmMultiple, 0.5F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(-3.3F * Scale * _pixelToMmMultiple, -0.8F * -1 * Scale * _pixelToMmMultiple, 0.8F * Scale * _pixelToMmMultiple, 0.5F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(2.5F * Scale * _pixelToMmMultiple, -0.8F * -1 * Scale * _pixelToMmMultiple, 0.8F * Scale * _pixelToMmMultiple, 0.5F * Scale * _pixelToMmMultiple)); Path.AddArc(-0.625F * Scale * _pixelToMmMultiple, 0.625F * -1 * Scale * _pixelToMmMultiple, 1.25F * Scale * _pixelToMmMultiple, 1.25F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-0.3F * Scale * _pixelToMmMultiple, 0.3F * -1 * Scale * _pixelToMmMultiple, 0.6F * Scale * _pixelToMmMultiple, 0.6F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-2.1F * Scale * _pixelToMmMultiple, 2.1F * -1 * Scale * _pixelToMmMultiple, 4.2F * Scale * _pixelToMmMultiple, 4.2F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddPolygon(new PointF[] { new PointF(-2.2F * Scale * _pixelToMmMultiple, -2.2F * -1 * Scale * _pixelToMmMultiple), new PointF(-2.2F * Scale * _pixelToMmMultiple, 1.5F * -1 * Scale * _pixelToMmMultiple), new PointF(-1.5F * Scale * _pixelToMmMultiple, 2.15F * -1 * Scale * _pixelToMmMultiple), new PointF(1.5F * Scale * _pixelToMmMultiple, 2.15F * -1 * Scale * _pixelToMmMultiple), new PointF(2.2F * Scale * _pixelToMmMultiple, 1.5F * -1 * Scale * _pixelToMmMultiple), new PointF(2.2F * Scale * _pixelToMmMultiple, -2.2F * -1 * Scale * _pixelToMmMultiple), new PointF(-2.1F * Scale * _pixelToMmMultiple, -2.2F * -1 * Scale * _pixelToMmMultiple) }); }
private void RenderValue(Canvas canvas, FitChartValue value) { if (!IsInEditMode) { var animationSeek = CalculateAnimationSeek(); var renderer = RendererFactory.Renderer(AnimationMode, value, drawingArea); var path = renderer.BuildPath(animationProgress, animationSeek); if (path != null) { canvas.DrawPath(path, value.Paint); } } else { var path = new Path(); path.AddArc(drawingArea, StartAngle, DesignModeSweepAngle); canvas.DrawPath(path, valueDesignPaint); } }
protected override void UpdatePath() { RGFloat min = Math.Min(Width, Height); RGFloat c = roundRate * min; Path.Reset(); if (c > 0) { Path.AddArc(0, 0, c, c, 180, 90); Path.AddArc(Width - c - 1, 0, c, c, 270, 90); Path.AddArc(Width - c - 1, Height - c, c, c, 0, 90); Path.AddArc(0, Height - c, c, c, 90, 90); Path.CloseAllFigures(); } else { Path.AddRectangle(new System.Drawing.RectangleF(0, 0, Width, Height)); } }
private void LCPath() { WidthF = 6.02F; HeightF = 6.02F; Path.StartFigure(); Path.AddLines(new PointF[] { new PointF(-2.2F * Scale * _pixelToMmMultiple, -1.9F * -1 * Scale * _pixelToMmMultiple), new PointF(-2.2F * Scale * _pixelToMmMultiple, 1.9F * -1 * Scale * _pixelToMmMultiple) }); Path.AddBezier(-2.2F * Scale * _pixelToMmMultiple, 1.9F * -1 * Scale * _pixelToMmMultiple, -2.2F * Scale * _pixelToMmMultiple, 2.2F * -1 * Scale * _pixelToMmMultiple, -1.9F * Scale * _pixelToMmMultiple, 2.2F * -1 * Scale * _pixelToMmMultiple, -1.9F * Scale * _pixelToMmMultiple, 2.2F * -1 * Scale * _pixelToMmMultiple); Path.AddLines(new PointF[] { new PointF(-1.59F * Scale * _pixelToMmMultiple, 2.2F * -1 * Scale * _pixelToMmMultiple), new PointF(-1.59F * Scale * _pixelToMmMultiple, 2.1F * -1 * Scale * _pixelToMmMultiple), new PointF(1.59F * Scale * _pixelToMmMultiple, 2.1F * -1 * Scale * _pixelToMmMultiple), new PointF(1.59F * Scale * _pixelToMmMultiple, 2.2F * -1 * Scale * _pixelToMmMultiple) }); Path.AddBezier(1.9F * Scale * _pixelToMmMultiple, 2.2F * -1 * Scale * _pixelToMmMultiple, 1.9F * Scale * _pixelToMmMultiple, 2.2F * -1 * Scale * _pixelToMmMultiple, 2.2F * Scale * _pixelToMmMultiple, 2.2F * -1 * Scale * _pixelToMmMultiple, 2.2F * Scale * _pixelToMmMultiple, 1.9F * -1 * Scale * _pixelToMmMultiple); Path.AddLines(new PointF[] { new PointF(2.2F * Scale * _pixelToMmMultiple, 1.9F * -1 * Scale * _pixelToMmMultiple), new PointF(2.2F * Scale * _pixelToMmMultiple, -1.9F * -1 * Scale * _pixelToMmMultiple) }); Path.AddBezier(2.2F * Scale * _pixelToMmMultiple, -1.9F * -1 * Scale * _pixelToMmMultiple, 2.2F * Scale * _pixelToMmMultiple, -1.9F * -1 * Scale * _pixelToMmMultiple, 2.2F * Scale * _pixelToMmMultiple, -2.2F * -1 * Scale * _pixelToMmMultiple, 1.9F * Scale * _pixelToMmMultiple, -2.2F * -1 * Scale * _pixelToMmMultiple); Path.AddLines(new PointF[] { new PointF(1.9F * Scale * _pixelToMmMultiple, -2.2F * -1 * Scale * _pixelToMmMultiple), new PointF(-1.9F * Scale * _pixelToMmMultiple, -2.2F * -1 * Scale * _pixelToMmMultiple) }); Path.AddBezier(-1.9F * Scale * _pixelToMmMultiple, -2.2F * -1 * Scale * _pixelToMmMultiple, -1.9F * Scale * _pixelToMmMultiple, -2.2F * -1 * Scale * _pixelToMmMultiple, -2.2F * Scale * _pixelToMmMultiple, -2.2F * -1 * Scale * _pixelToMmMultiple, -2.2F * Scale * _pixelToMmMultiple, -1.9F * -1 * Scale * _pixelToMmMultiple); Path.CloseFigure(); Path.StartFigure(); Path.AddLines(new PointF[] { new PointF(-2.1F * Scale * _pixelToMmMultiple, -1.8F * -1 * Scale * _pixelToMmMultiple) }); Path.AddBezier(-2.1F * Scale * _pixelToMmMultiple, 1.8F * -1 * Scale * _pixelToMmMultiple, -2.1F * Scale * _pixelToMmMultiple, 2.1F * -1 * Scale * _pixelToMmMultiple, -1.8F * Scale * _pixelToMmMultiple, 2.1F * -1 * Scale * _pixelToMmMultiple, -1.8F * Scale * _pixelToMmMultiple, 2.1F * -1 * Scale * _pixelToMmMultiple); Path.AddLines(new PointF[] { new PointF(-1.8F * Scale * _pixelToMmMultiple, 2.1F * -1 * Scale * _pixelToMmMultiple), new PointF(1.8F * Scale * _pixelToMmMultiple, 2.1F * -1 * Scale * _pixelToMmMultiple) }); Path.AddBezier(1.8F * Scale * _pixelToMmMultiple, 2.1F * -1 * Scale * _pixelToMmMultiple, 2.1F * Scale * _pixelToMmMultiple, 2.1F * -1 * Scale * _pixelToMmMultiple, 2.1F * Scale * _pixelToMmMultiple, 1.8F * -1 * Scale * _pixelToMmMultiple, 2.1F * Scale * _pixelToMmMultiple, 1.8F * -1 * Scale * _pixelToMmMultiple); Path.AddLines(new PointF[] { new PointF(2.1F * Scale * _pixelToMmMultiple, 1.2F * -1 * Scale * _pixelToMmMultiple), new PointF(2.1F * Scale * _pixelToMmMultiple, -1.2F * -1 * Scale * _pixelToMmMultiple) }); Path.AddBezier(2.1F * Scale * _pixelToMmMultiple, -1.8F * -1 * Scale * _pixelToMmMultiple, 2.1F * Scale * _pixelToMmMultiple, -1.8F * -1 * Scale * _pixelToMmMultiple, 2.1F * Scale * _pixelToMmMultiple, -2.1F * -1 * Scale * _pixelToMmMultiple, 1.8F * Scale * _pixelToMmMultiple, -2.1F * -1 * Scale * _pixelToMmMultiple); Path.AddLines(new PointF[] { new PointF(1.8F * Scale * _pixelToMmMultiple, -2.1F * -1 * Scale * _pixelToMmMultiple), new PointF(-1.8F * Scale * _pixelToMmMultiple, -2.1F * -1 * Scale * _pixelToMmMultiple) }); Path.AddBezier(-1.8F * Scale * _pixelToMmMultiple, -2.1F * -1 * Scale * _pixelToMmMultiple, -2.1F * Scale * _pixelToMmMultiple, -2.1F * -1 * Scale * _pixelToMmMultiple, -2.1F * Scale * _pixelToMmMultiple, -1.8F * -1 * Scale * _pixelToMmMultiple, -2.1F * Scale * _pixelToMmMultiple, -1.8F * -1 * Scale * _pixelToMmMultiple); Path.CloseFigure(); Path.StartFigure(); Path.AddRectangle(new RectangleF(-1.6F * Scale * _pixelToMmMultiple, 2.39F * -1 * Scale * _pixelToMmMultiple, 3.2F * Scale * _pixelToMmMultiple, 0.29F * Scale * _pixelToMmMultiple)); Path.CloseFigure(); Path.StartFigure(); Path.AddRectangle(new RectangleF(-1.6F * Scale * _pixelToMmMultiple, 2.59F * -1 * Scale * _pixelToMmMultiple, 3.2F * Scale * _pixelToMmMultiple, 0.2F * Scale * _pixelToMmMultiple)); Path.CloseFigure(); Path.StartFigure(); Path.AddArc(-0.625F * Scale * _pixelToMmMultiple, 0.625F * -1 * Scale * _pixelToMmMultiple, 1.25F * Scale * _pixelToMmMultiple, 1.25F * Scale * _pixelToMmMultiple, 180F, 360F); Path.CloseFigure(); Path.StartFigure(); Path.AddArc(-0.3F * Scale * _pixelToMmMultiple, 0.3F * -1 * Scale * _pixelToMmMultiple, 0.6F * Scale * _pixelToMmMultiple, 0.6F * Scale * _pixelToMmMultiple, 180F, 360F); Path.CloseFigure(); Path.StartFigure(); Path.AddArc(-1.5F * Scale * _pixelToMmMultiple, 1.5F * -1 * Scale * _pixelToMmMultiple, 3F * Scale * _pixelToMmMultiple, 3F * Scale * _pixelToMmMultiple, 180F, 360F); Path.CloseFigure(); }
private void WireWrapPath() { WidthF = 20F; HeightF = 2F; Path.AddRectangle(new RectangleF(-10F * Scale * _pixelToMmMultiple, 1F * -1 * Scale * _pixelToMmMultiple, 20F * Scale * _pixelToMmMultiple, 2F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(-9.215F * Scale * _pixelToMmMultiple, 0.325F * -1 * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(-6.675F * Scale * _pixelToMmMultiple, 0.325F * -1 * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(-4.135F * Scale * _pixelToMmMultiple, 0.325F * -1 * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(-1.595F * Scale * _pixelToMmMultiple, 0.325F * -1 * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(0.945F * Scale * _pixelToMmMultiple, 0.325F * -1 * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(3.485F * Scale * _pixelToMmMultiple, 0.325F * -1 * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(6.025F * Scale * _pixelToMmMultiple, 0.325F * -1 * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple)); Path.AddRectangle(new RectangleF(8.565F * Scale * _pixelToMmMultiple, 0.325F * -1 * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple)); Path.AddArc(-9.215F * Scale * _pixelToMmMultiple, 0.3175F * -1 * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-6.675F * Scale * _pixelToMmMultiple, 0.325F * -1 * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-4.135F * Scale * _pixelToMmMultiple, 0.3255F * -1 * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(-1.595F * Scale * _pixelToMmMultiple, 0.325F * -1 * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(0.945F * Scale * _pixelToMmMultiple, 0.325F * -1 * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(3.485F * Scale * _pixelToMmMultiple, 0.325F * -1 * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(6.025F * Scale * _pixelToMmMultiple, 0.325F * -1 * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 180F, 360F); Path.AddArc(8.565F * Scale * _pixelToMmMultiple, 0.325F * -1 * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 0.65F * Scale * _pixelToMmMultiple, 180F, 360F); }