def caret_position=(position)
      raise ArgumentError, "Caret position must be in the range 0 to the length of the text (inclusive)" unless position.between?(0, stripped_text.length)
      @text_input.caret_pos = position

      position
    end
def caret_position=(position)
      raise ArgumentError, "Caret position must be in the range 0 to the length of the text (inclusive)" unless position.between?(0, stripped_text.length)
      @text_input.caret_pos = position

      position
    end
Position of the caret.

 @param [Integer] pos Position of caret in the text.
 @return [Integer] New position of caret.