Adds the text from string beginning to the specified ending
        index to the format.

        :param end: The ending index of the string.
        :param next: The next string begin index.  If None, the string
                     index will not be updated.

def add_text(self, end, next=None):
        """
        Adds the text from string beginning to the specified ending
        index to the format.

        :param end: The ending index of the string.
        :param next: The next string begin index.  If None, the string
                     index will not be updated.
        """

        if self.str_begin != end:
            self.fmt.append_text(self.format[self.str_begin:end])

        if next is not None:
            self.str_begin = next