| |
- check_answer(win_obj, _=None)
- A function that verify the answer
and updates the interface according to it.
Input:
- buttons : the four buttons of the interface
- inpt : the input field of the interface
- _ : an unused parameter sent from an event (when key <Return> is hit)
- conf_commands(win_obj)
- Configures the command bound to the buttons and entry field.
- next_stce(win_obj, minus='-100')
- A function that updates the data and the interface with a new sentence.
Input:
- buttons : the four buttons of the interface
- minus : a string representiing the number of point
to remove from the player's score
- replay(win_obj, vict=None)
- A function that lauches a new game
and updates the interface
Input:
- buttons : the four buttons of the interface
- inpt : the input field of the interface
- vict : the victory window if it has been created
- set_score(win_obj)
- A function that updates and fills the printed score according to its values
- update_canvas(win_obj)
- A function that updates the printed text and make it scrolled to the bottom.
- victory(win_obj)
- A function that draws a victory window,
asking if the player want to quit or to replay
Input :
- buttons : the list of four bottom buttons
- win_bot(panel, win_obj)
- Creates the bottom half of the window.
- win_bot_left(panel_bot, win_obj)
- Create the left part (the input field)
of the bottom part of the window.
- win_bot_right(panel_bot, win_obj)
- Create the right part (the buttons)
of the bottom part of the window.
- win_create()
- Creates the window and returns a dictionnary with key elements.
- win_top(panel, win_obj)
- Creates the top half of the window.
- win_top_left(panel_top, win_obj)
- Creates the left part (the text area)
of the top part of the window.
- win_top_right(panel_top, win_obj)
- Create the right part (the score display)
of the top part of the window.
|