Adding callbacks to terminal.