在 MigraDoc 中识别文本文件换页
MigraDoc 有没有办法识别已嵌入 ASCII 文本文件中的换页字符?或者是否必须逐行处理文本文件才能捕获它们?
Is there a way for MigraDoc to recognize form feeds characters that are already embedded in a ASCII text file? Or does one have to process the text file line by line to catch them?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我不认为 MigraDoc 自动将“换页符”视为分页符。
如果您无论如何处理文本文件,输出可能看起来会更好(例如,仅将单个 CR/LF 视为空格,将空行视为新段落等)。
忽略换页甚至可能是有意义的 - 文本文件可能不是为比例字体制作的。如果您在 MigraDoc 中使用比例字体(例如 Arial),则文档可以容纳更少的页面。
I don't think that "form feeds" are treated as page breaks by MigraDoc automatically.
The output probably looks better if you process the text file anyway (e.g. treat single CR/LF as spaces only, treat empty lines as new paragraphs, etc.).
It could even make sense to ignore the form feeds - the text files probably weren't made for proportional fonts. If you use proportional fonts with MigraDoc (e.g. Arial), the documents could fit on a smaller number of pages.