'Turn on the internal consistency checks of the B-Tree inside the text
widget according to BOOLEAN.'

def debug(self, boolean=None):

    if (boolean is None):
        return self.tk.getboolean(self.tk.call(self._w, 'debug'))
    self.tk.call(self._w, 'debug', boolean)
