Texts Rich Text Format for hiding and hiding

I would like to hide part of the text in a RichTextBox. I know that \ v is the beginning of the hide section. But how do I show? For example, if I want to hide the word “big” in the line “hello big world” to see “hello world”:


text : "hello big world" RTF so far : "hello \v big world" result : "hello " wanted result -> : "hello world" doesn't work : "hello \v big\v world" 


Is there any way?
+4
source share
2 answers

Alex K.'s solution is probably better, but I am adding this solution that I just found because it also works. \plain resets the default text style:

 hello \v big\plain world 

Another solution (actually used by RichTextBoxes): \v0 disables only hiding

 hello \v big\v0 world 
+9
source

To group code, you need to use curly braces;

 "hello {\v big} world" 
+6
source

All Articles