(self, data, parent=None)
Insert text data.
Insert text data.
Insert text data .
def insertText(self, data, parent=None):
        """Insert text data."""
        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:
            # We should be in the InTable mode. This means we want to do
            # special magic element rearranging
            parent, insertBefore = self.getTableMisnestedNodePosition()
            parent.insertText(data, insertBefore)
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 : # We should be in the InTable mode. This means we want to do # special magic element rearranging parent , insertBefore = self . getTableMisnestedNodePosition ( ) parent . insertText ( data , insertBefore )