我有问题,
我有圆角矩形。它只在右侧是圆形的,在左侧是直的。我想用其他方式来做——左圆,右直。我应该改变什么?
int ArcWidth = 10 * 2;
int ArcHeight = 10 * 2;
int ArcX1 = Rect.Left;
int ArcX2 = Rect.Right -(ArcWidth + 1);
int ArcY1 = Rect.Top;
int ArcY2 = Rect.Bottom -(ArcHeight + 1);
path.AddArc(ArcX1, ArcY1, 1, 1, 180, 90); // Top Left
path.AddArc(ArcX2, ArcY1, ArcWidth, ArcHeight, 270, 90); //Top Right
path.AddArc(ArcX2, ArcY2, ArcWidth, ArcHeight, 360, 90); //Bottom Right
path.AddArc(ArcX1, ArcY2, 1, ArcHeight, 90, 90); //Bottom Left