'Makes the given element the immediate successor of this one.
The two elements will have the same parent, and the given element
will be immediately after this one.'

def insert_after(self, successor):

    if (self is successor):
        raise ValueError("Can't    insert    an    element    after    itself.")
    parent = self.parent
    if (parent is None):
        raise ValueError("Element    has    no    parent,    so    'after'    has    no    meaning.")
    if isinstance(successor, PageElement):
        successor.extract()
    index = parent.index(self)
    parent.insert((index + 1), successor)
