RTF 文件中关键字的截断
我们将数据嵌入 RTF 文件的 \keywords
字段中。 \keywords
标记在文件中通过“字符串替换”进行更新,而不是使用任何类型的 RTF API。
当我们在Word 2007中打开RTF文件时,该文件的keywords属性似乎只显示\keywords
标签的前520个字符。如果我直接从 Word 2007 编辑此字段(超过 520 个字符),则在将文件保存到磁盘之前似乎没问题。
您觉得这是预期的行为吗?能够在 Word 中键入任意长度的关键字,但在保存/关闭/重新打开文件后丢失它们?
可能 RTF 规范明确指出该字段不能存储更多 520 字节(不是 512)...但我没有找到任何相关信息。
预先感谢您的任何帮助。
顺便问一下,您知道一些嵌入数据的备份字段吗?
we are embedding data in the \keywords
field of a RTF file. The \keywords
tag is updated in the file with sort of "String replacement", not by using any kind of RTF API.
It appears that when we open the RTF file in Word 2007, the keywords property of the file only display the first 520 characters of the \keywords
tag. If I edit this field directly from Word 2007, with more than 520 characters, it seems ok until I save the file to the disk.
Does it feel to you as the expected behavior? Be able to type keywords of any length in Word but loosing them after having saved/closed/reopened the file?
May be the RTF specification states explicitly that the field can't store more 520 bytes (not 512)... but I don't find anything about it.
Thanks in advance for any help.
And by the way, do you know some backup field to embed data?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我最终使用了 \keywords 和 \description 标签。
I ended up by using both \keywords and \description tags.