'Insert `widget` into the stack at `index`.'

def insertWidget(self, index, widget):

    index = min(index, self.count())
    self.__widgets.insert(index, widget)
    if ((index <= self.__currentIndex) or (self.__currentIndex == (-1))):
        self.__currentIndex += 1
    return self.layout().insertWidget(index, widget)
