Open v1km4n opened 1 year ago
Hi,
I modified the class "TextSelection" to take into account the new lines :
case TextPointerContext.EmbeddedElement:
var nextInsertionPosition = p.GetNextInsertionPosition(LogicalDirection.Forward);
if (nextInsertionPosition != null && new TextRange(p, nextInsertionPosition).Text.Contains(Environment.NewLine))
buf.AppendLine();
break;
RichTextBox input looks like this:
RichTextBox.Text ignores newline and returns this:
Using TextRange(RichTextBox.Document.ContentStart, RichTextBox.Document.ContentStart).text (the usual method for extracting RichTextBox text) ignores all the emojis and returns this: Which is understandable since TextRange probably doesn't support emoji at all
I wasn't able to find any workarounds, so please tell me if there is any, but as of now it just looks like newline is ignored completely