(self, text)
Initialize data attributes and bind event methods.

        .text - Idle wrapper of tk Text widget, with .bell().
        .history - source statements, possibly with multiple lines.
        .prefix - source already entered at prompt; filters history list.
        .pointer - index into history.
        .cyclic - wrap around history list (or not).
Initialize data attributes and bind event methods.
Initialize data attributes and bind event methods .
def __init__(self, text):
        '''Initialize data attributes and bind event methods.

        .text - Idle wrapper of tk Text widget, with .bell().
        .history - source statements, possibly with multiple lines.
        .prefix - source already entered at prompt; filters history list.
        .pointer - index into history.
        .cyclic - wrap around history list (or not).
        '''
        self.text = text
        self.history = []
        self.prefix = None
        self.pointer = None
        self.cyclic = idleConf.GetOption("main", "History", "cyclic", 1, "bool")
        text.bind("<<history-previous>>", self.history_prev)
        text.bind("<<history-next>>", self.history_next)
def __init__ ( self , text ) : self . text = text self . history = [ ] self . prefix = None self . pointer = None self . cyclic = idleConf . GetOption ( "main" , "History" , "cyclic" , 1 , "bool" ) text . bind ( "<<history-previous>>" , self . history_prev ) text . bind ( "<<history-next>>" , self . history_next )