libqtile/layout/tree.py
def del_section(self, name):
        """Remove the Section with the given name"""
        if name not in self.sections:
            raise ValueError("Section name not found")
        if len(self.children) == 1:
            raise ValueError("Can't delete last section")

        sec = self.sections[name]
        # move the children of the deleted section to the previous section
        # if delecting the first section, add children to second section
        idx = min(self.children.index(sec), 1)
        next_sec = self.children[idx - 1]
        # delete old section, reparent children to next section
        del self.children[idx]
        next_sec.children.extend(sec.children)
        for i in sec.children:
            i.parent = next_sec
Remove the Section with the given name
Remove the Section with the given name
Remove the Section with the given name
def del_section(self, name):
        if name not in self.sections:
            raise ValueError("Section name not found")
        if len(self.children) == 1:
            raise ValueError("Can't delete last section")
        sec = self.sections[name]
        idx = min(self.children.index(sec), 1)
        next_sec = self.children[idx - 1]
        del self.children[idx]
        next_sec.children.extend(sec.children)
        for i in sec.children:
            i.parent = next_sec
def del_section ( self , name ) : if name not in self . sections : raise ValueError ( "Section name not found" ) if len ( self . children ) == 1 : raise ValueError ( "Can't delete last section" ) sec = self . sections [ name ] idx = min ( self . children . index ( sec ) , 1 ) next_sec = self . children [ idx - 1 ] del self . children [ idx ] next_sec . children . extend ( sec . children ) for i in sec . children : i . parent = next_sec
Remove the Section with the given name
Remove the Section with the given name
"""Remove the Section with the given name""" # move the children of the deleted section to the previous section # if delecting the first section, add children to second section # delete old section, reparent children to next section
self
name