def setExpandRatio(self, component, ratio):
        if component in self.components:
            self._componentToExpandRatio[component] = ratio
            self.requestRepaint()
        else:
            raise ValueError, ('Component must be added to layout '
                    'before using setExpandRatio()')
This method is used to control how excess space in layout
dataset/ETHPy150Open rwl/muntjac/muntjac/ui/abstract_ordered_layout.py/AbstractOrderedLayout.setExpandRatio