(self, wnd, pos, posto, update_cursor=True)
Delete string
Delete string
Delete string
def delete_string(self, wnd, pos, posto, update_cursor=True):
        """Delete string"""

        cur_pos = wnd.cursor.pos

        if pos < posto:
            deled = wnd.document.gettext(pos, posto)
            wnd.document.delete(pos, posto)

            if update_cursor:
                wnd.cursor.setpos(pos)
                wnd.cursor.savecol()

            if wnd.document.undo:
                wnd.document.undo.add(self.UNDO_DELETE, pos, posto, deled,
                                      cur_pos, wnd.cursor.pos)
            self.on_edited(wnd)
def delete_string ( self , wnd , pos , posto , update_cursor = True ) : cur_pos = wnd . cursor . pos if pos < posto : deled = wnd . document . gettext ( pos , posto ) wnd . document . delete ( pos , posto ) if update_cursor : wnd . cursor . setpos ( pos ) wnd . cursor . savecol ( ) if wnd . document . undo : wnd . document . undo . add ( self . UNDO_DELETE , pos , posto , deled , cur_pos , wnd . cursor . pos ) self . on_edited ( wnd )