@@ -771,22 +771,22 @@ protected void arcImpl(float x, float y, float w, float h,
771
771
float centerX = rect .centerX ();
772
772
float centerY = rect .cenerY ();
773
773
774
- float startX = (float ) (halfWidth * Math .cos (Math .toRadians (start ))) + centerX ;
775
- float startY = (float ) (halfHeight * Math .sin (Math .toRadians (start ))) + centerY ;
776
- float endX = (float ) (halfWidth * Math .cos (Math .toRadians (endAngle ))) + centerX ;
777
- float endY = (float ) (halfHeight * Math .sin (Math .toRadians (endAngle ))) + centerY ;
774
+ float startX = (float ) (halfRectWidth * Math .cos (Math .toRadians (start ))) + centerX ;
775
+ float startY = (float ) (halfRectHeight * Math .sin (Math .toRadians (start ))) + centerY ;
776
+ float endX = (float ) (halfRectWidth * Math .cos (Math .toRadians (endAngle ))) + centerX ;
777
+ float endY = (float ) (halfRectHeight * Math .sin (Math .toRadians (endAngle ))) + centerY ;
778
778
779
779
if (fill ){
780
780
// draw the fill arc
781
781
canvas .drawArc (rect ,start ,sweep ,false ,fillPaint );
782
782
// draw the arc round border
783
- canvas .drawAcr (rect ,start ,sweep ,false ,strokePaint );
783
+ canvas .drawArc (rect ,start ,sweep ,false ,strokePaint );
784
784
// draw the straight border
785
785
canvas .drawLine (startX ,startY ,endX ,endY ,strokePaint );
786
786
}
787
787
if (stroke ) {
788
788
// draw the arc
789
- canvas .drawAcr (rect ,start ,sweep ,false ,strokePaint );
789
+ canvas .drawArc (rect ,start ,sweep ,false ,strokePaint );
790
790
// draw the straight border
791
791
canvas .drawLine (startX ,startY ,endX ,endY ,strokePaint );
792
792
}
0 commit comments