BioSANS2020.gui_functs.scrollable_text
¶
This is the scrollable_text module
This module controls how text area are placed inside the canvas for displaying output of computation, equations, etc.
The following is the list of function for this module:
save_file
tab
delete_this
prepare_scroll_text
Module Contents¶
Functions¶
|
Opens a file dialog box for saving the constents of the text area |
|
insers tab or four spaces in the text area |
|
This function update the canvas upon adding new objects by moving |
|
This function removes objects from the canvas and reorder objects |
|
This function prepares the scrollable text area by creating a |
- BioSANS2020.gui_functs.scrollable_text.save_file(_, text)¶
Opens a file dialog box for saving the constents of the text area
- BioSANS2020.gui_functs.scrollable_text.tab(_, text)¶
insers tab or four spaces in the text area
- BioSANS2020.gui_functs.scrollable_text.canvas_update_widgets(_, canvas)¶
This function update the canvas upon adding new objects by moving objects to ensure they fit nicely. The arrangement is that the last object added appear first (latest goes on top). Args:
canvas : the canvas object
- BioSANS2020.gui_functs.scrollable_text.delete_this(frame, canvas)¶
This function removes objects from the canvas and reorder objects
- BioSANS2020.gui_functs.scrollable_text.prepare_scroll_text(items)¶
This function prepares the scrollable text area by creating a frame as a child of the canvas or items[0]. Scroll capabilities are added and a Text area is created as a child of the frame. Args:
items : 3 item list of [canvas, scroll_x, scroll_y]
- Returns:
text : the text area object where text can be inserted