pdtextfield的连续线馈送
我想在设置pdtextfield
值时保留线供稿,但是似乎未打印连续的行馈送?
给定此值字符串:“ this \ n \ nis \ na \ ntest”
我希望这个输出:
This
is
a
test
但是我会得到:
This
is
a
test
而是。
最小示例:
val acroForm = document.documentCatalog.acroForm
val field = acroForm.getField("text_field") as PDTextField
field.isMultiline = true
field.value = "This\n\nis\na\ntest"
PDFBox 2.0.25
I'd like to preserve the line feeds when setting a PDTextField
value, but it seems that consecutive line feeds are not printed out?
Given this value string: "This\n\nis\na\ntest"
I'd expect this output:
This
is
a
test
But I'm getting:
This
is
a
test
instead.
Minimal example:
val acroForm = document.documentCatalog.acroForm
val field = acroForm.getField("text_field") as PDTextField
field.isMultiline = true
field.value = "This\n\nis\na\ntest"
PDFBox 2.0.25
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论