Hi,
I would like to create an Ellipse Shape that will be inserted into a line of text. I am unsure of how to accomplish 2 things:
I want the ellipse to be the same height as the text.
I want the text to be aware of the ellipse so that adding more text before the shape causes it to move rather than just hide behind or go in front of the shape.
Hi
Thanks for your inquiry. I think that you should make shape to be inline with text. Please try using the following code:
// Create document
Document doc = new Document();
// Create DocumentBuilder
DocumentBuilder builder = new DocumentBuilder(doc);
// Insert some text
builder.Write("This is text before shape");
// Create elipse shape
Shape elipse = new Shape(doc, ShapeType.Ellipse);
// Set size of shape
elipse.Width = 12;
elipse.Height = 12;
// Set WrapType
elipse.WrapType = WrapType.Inline;
// Insert shape into the document
builder.InsertNode(elipse);
// Insert some text
builder.Write("Some text sfter shape");
// Save document
doc.Save(@"Test057\out.doc");
I hope this helps.
Best regards.
Cookie Notice
To provide you with the best experience, we use cookies for personalization, analytics, and ads. By using our site, you agree to our cookie policy.
Enables storage, such as cookies, related to analytics.
Sets consent for sending user data to Google for online advertising purposes.
Sets consent for personalized advertising.
Cookie Notice
To provide you with the best experience, we use cookies for personalization, analytics, and ads. By using our site, you agree to our cookie policy.
More info
Enables storage, such as cookies, related to analytics.
Enables storage, such as cookies, related to advertising.
Sets consent for sending user data to Google for online advertising purposes.
Sets consent for personalized advertising.
Cookie Notice
To provide you with the best experience, we use cookies for personalization, analytics, and ads. By using our site, you agree to our cookie policy.
More info
Enables storage, such as cookies, related to analytics.
Enables storage, such as cookies, related to advertising.
Sets consent for sending user data to Google for online advertising purposes.