RichTextBox将内容另存为rtf是一个错误吗? [英] RichTextBox save content as rtf is it a bug?

查看:44
本文介绍了RichTextBox将内容另存为rtf是一个错误吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好

我在使用RichTextBox时遇到问题

I have a problem to use RichTextBox

我们使用RichTextBox,其方向为rtf,并向其中写入一些多级列表,如

we use a RichTextBox, its direction is rtf and we write to it some multilevel list like

1.aaa

2.bbb

     1.aaa

      1.aaa

      2.bbb

       2.bbb

将RichTextBox的文本保存为Rtf格式并重新加载此rtf文本(或在MSWord中打开)后,它会破坏列表格式和文本间距,以新格式显示它喜欢的内容

after save text of RichTextBox as Rtf format and reload this rtf text(or open it in MSWord)it destroys list format and spaceing of text, in new format it shows it likes

1.aaa

2.bbb

1. aaa

2. bbb

我在不同情况下进行了测试:如果Direction将为LTR,则效果很好

I test it in different situation: if Direction will be LTR it works fine

如果加载在RichTextBox中破坏文本并再次保存,将破坏文本以真实格式保存

If load  destroyed text in RichTextBox and save it again it save destroyed text in true format

似乎销毁格式的文本还有2个字符会销毁文本.

It seems destroyed format text has 2 more character that destroys text.

这是一个错误吗?

感谢任何帮助或想法

推荐答案

mojtaba sarooghi,

根据我的理解,RTF格式和RTB FlowDocument格式是两种不同的数据格式.某些指定的功能不能相同. RTF没有明确的清单 元素.请注意,RTF段落只是列表项,当我们转换时 转换为RTF格式 我们失去了两个列表之间的区别.

Based on my understanding, RTF format and RTB FlowDocument format are two different dataformats. Some specified features cannot be the same. RTF doesn’t have explicit list elements. Please be aware of that RTF paragraphs are simply list items and when we convert to RTF format we lose the distinction between two lists. 

如果您认为RTB的此功能不太理想,也可以通过正式方式将其提交到以下网站:

提高产品和服务的质量对Microsoft来说是一个永无止境的过程.

 

最诚挚的问候,

Yves


这篇关于RichTextBox将内容另存为rtf是一个错误吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆