Hello!
I want change the radius of corners of a rounded rectangle.
In this post (Need help in drawing Shapes in MSWord) says that it is not supported.
Is this function implemented now?
Unfortunately, this feature is not supported by Aspose.Words yet. The feature ID is WORDSNET-5854. We will inform you via this forum thread once this feature is available.
We apologize for your inconvenience.
Hi,
Is there any estimated delivery time for WORDSNET-5854? It would be very useful for us as well.
Thanks
@acturisaspose Unfortunately, there are no news regarding the issue. It has been postponed and is not yet scheduled for development. Please accept out apologies for your inconvenience.
But you can change the rounding radius using shape adjustments. Please see Shape.Adjustments
.
For example see the following code:
Document doc = new Document();
Shape s = new Shape(doc, ShapeType.RoundRectangle);
s.Width = 100;
s.Height = 100;
// Change shape adjustment
s.Adjustments[0].Value = s.Adjustments[0].Value / 2;
doc.FirstSection.Body.FirstParagraph.AppendChild(s);
doc.Save(@"C:\Temp\out.docx");
In the model arcsize
is stored in adj1
. In VML it is stored as percentage. The value is calculated using the following code:
double percent = (double)adj1 / shape.CoordSizeWidth;
It works perfectly, thanks!