def split_focus(self):
        """Divide the focus edit widget at the cursor location."""

        focus = self.lines[self.focus]
        pos = focus.edit_pos
        edit = urwid.Edit("", focus.edit_text[pos:], allow_tab=True)
        edit.original_text = ""
        focus.set_edit_text(focus.edit_text[:pos])
        edit.set_edit_pos(0)
        self.lines.insert(self.focus + 1, edit)
def split_focus ( self ) : focus = self . lines [ self . focus ] pos = focus . edit_pos edit = urwid . Edit ( "" , focus . edit_text [ pos : ] , allow_tab = True ) edit . original_text = "" focus . set_edit_text ( focus . edit_text [ : pos ] ) edit . set_edit_pos ( 0 ) self . lines . insert ( self . focus + 1 , edit )
Divide the focus edit widget at the cursor location.