Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想知道是否有人在地铁中使用过 RichEditBox。我正在寻找如何根据搜索突出显示项目的选择。
我注意到有一个作为属性公开的文档对象,但这似乎是只读的,我似乎无法找到您将如何更新选择(我假设它与 SL / WPF 中的流文档相同)。
怎么样:
Windows.UI.Text.ITextSelection selection = richEditBox.Document.Selection; selection.StartPosition = 0; selection.EndPosition = n;