'Insert text data.'

def insertText(self, data, parent=None):

    if (parent is None):
        parent = self.openElements[(-1)]
    if ((not self.insertFromTable) or (self.insertFromTable and (self.openElements[(-1)].name not in tableInsertModeElements))):
        parent.insertText(data)
    else:
        (parent, insertBefore) = self.getTableMisnestedNodePosition()
        parent.insertText(data, insertBefore)
