我正在向画布动态添加一个 Rectangle 对象,DrawImageTest
如下所述:
System.Windows.Shapes.Rectangle rectToDraw = ToRectangle(rect);
DrawImageTest.Children.Add(rectToDraw);
你能告诉我如何通过代码动态删除这个rectToDraw
矩形对象吗?Canvas
我正在向画布动态添加一个 Rectangle 对象,DrawImageTest
如下所述:
System.Windows.Shapes.Rectangle rectToDraw = ToRectangle(rect);
DrawImageTest.Children.Add(rectToDraw);
你能告诉我如何通过代码动态删除这个rectToDraw
矩形对象吗?Canvas