PDFsharp & MigraDoc Foundation

Tight wrapping for shapes
Page 1 of 1

Author:  crypto_rsa [ Wed Apr 22, 2015 10:45 am ]
Post subject:  Tight wrapping for shapes


currently the WrapStyle of a shape can be one of these: WrapStyle.TopBottom, WrapStyle.None, WrapStyle.Through. Can another value, WrapStyle.Tight, be added which would cause the text around the shape be wrapped tightly? It would correspond to the control word /shpwr4 in an exported RTF file.
In my document I have an image wrapped in a TextFrame which is positioned relative to the whole page but I can't make the wrapping work correctly.

Author:  Thomas Hoevel [ Wed Apr 22, 2015 11:18 am ]
Post subject:  Re: Tight wrapping for shapes


This is not my area of expertise, but it probably can easily be implemented for the RTF renderer. But we won't be able to support this flag for the PDF renderer in the foreseeable future.

Are you rendering to RTF?

Author:  crypto_rsa [ Wed Apr 22, 2015 12:09 pm ]
Post subject:  Re: Tight wrapping for shapes

Thomas Hoevel wrote:
Are you rendering to RTF?

I am rendering to both RTF and PDF. Actually I don't need "true" tight wrapping, including non-rectangular shapes. I just need the functionality of the WrapStyle.TopBottom value, but with the top and bottom margins being essentially zero, so that the text frame is placed right under the paragraph above it. However, in RtfRendering.ShapeRenderer.RenderWrapFormat the 'distance' properties of WrapFormat are ignored.

Page 1 of 1 All times are UTC
Powered by phpBB® Forum Software © phpBB Group