An example on appending a tab character to xamTextEditor by pressing ctrl + tab.
This can be done by handling the KeyDown event in which "\t" can be appended to the editor's value. To set the caret position is from the textbox element and can be returned from VisualTreeHelper.