Saves the current state (caret position and the text inside) of a TextEntry as an undo state.
See also Panel:Undo.