ae.gui.utils
GUI app constants and helper functions
Module Attributes
config section name to store app state |
|
config variable name to store the current application state version |
|
minimum (see |
|
black ink |
|
dark grey ink |
|
grey ink |
|
light grey ink |
|
white ink |
|
beginning angle for ellipse drawings via |
|
ending angle for ellipse drawings via |
|
dark theme background color in rgba(0.0 . |
|
dark theme font color in rgba(0.0 . |
|
light theme background color in rgba(0.0 . |
|
light theme font color in rgba(0.0 . |
|
config-files section name prefix for to store app theme vars |
|
mangle app state var names to not be interpreted as user-specific |
|
separator character between flow action/object and flow key |
|
regular expression detecting invalid characters in flow action string |
|
regular expression detecting invalid characters in flow object string |
|
message id prefix for app state change help texts |
|
message id prefix for flow change help texts |
|
message id prefix of tour page text/dict |
|
default value of tour start delay in seconds |
|
default value of tour exit delay in seconds |
|
app image files register |
|
app audio/sound files register |
|
map(name: class) of all registered tour classes |
|
(see return value of |
|
app state config variable type |
|
color red, green and blue parts |
|
ink is rgb color and alpha |
|
color or ink type |
|
change flow event kwargs type |
|
single explained widget matcher type |
|
help context variables for help text rendering |
|
popups to close on button-press/flow-change |
|
tuple of top/bottom relief colors or empty tuple |
|
used. |
Functions
|
calculate the anchor's x position of the layout box. |
|
calculate the layout box y position of an anchor. |
|
recalculate points of the anchor triangle drawing. |
|
calculate anchor center pos (x, y) and anchor direction to the targeted widget. |
|
brightens the specified color/ink without changing an optionally passed alpha/occupancy value. |
|
convert HSV-color (H: 0-360, S: 0-1, V: 0-1) into its corresponding RGB color. |
|
convert color/ink to its HSV values. |
|
determine the complementary color or ink without changing an optionally passed alpha/occupancy value. |
|
darkens the specified color/ink without changing an optionally passed alpha/occupancy value. |
|
calculate the radius from polar for the given ellipse and radian. |
|
ensure that the passed widget.__init__ kwargs dict contains a reference to itself within kwargs['tap_kwargs']. |
|
determine the action string of a flow_id. |
|
split flow id string into the action part and the rest. |
|
determine the name of the event method for the change confirmation of the passed flow_id. |
|
determine the class name for the given flow id and class name suffix. |
|
return the key of a flow id. |
|
split flow id into an action, object and flow key. |
|
determine the object string of the passed flow_id. |
|
determine the flow id of the newest/last entry in the flow_path. |
|
return a copy of the specified flow_path with all non-enter actions stripped from the end. |
|
determine the name of the Popup class for the given flow id. |
|
determine the tour class if passed help id has attached tour pages. |
|
determine sub id (flow id, tour id or app state name) of the current/specified/passed help id. |
|
create flow id string. |
|
compose help id for specified flow id. |
|
compose help id for app state name/key. |
|
compose help id for specified tour page id. |
|
merge the popups_to_close item values of the two specified tap_kwargs dicts. |
|
mix multiple colors or inks into a single one. |
|
type-check and bundle args of the MainAppClass.show_*() methods into a single event kwargs dict for a FlowPopup. |
call from the module scope of the package to register/add the image/img resources path. |
|
call from the module scope of the package to register/add sound file resources. |
|
|
calculate the top-left and bottom-right colors used for square/ellipse relief effects. |
|
replace action in the given flow id. |
|
determine help translation for the passed page id (flow id or app state name). |
|
determine the tour class of the passed tour id. |
|
check if a help text exists for the passed help id. |
|
update or simulate a widget's tap_kwargs property and return the updated dictionary (for kv rule of tap_kwargs). |
|
determine tour page id of passed widget. |
- APP_STATE_SECTION_NAME = 'aeAppState'
config section name to store app state
- APP_STATE_VERSION_VAR_NAME = 'app_state_version'
config variable name to store the current application state version
- MIN_FONT_SIZE = 15.0
minimum (see
min_font_size) and
- MAX_FONT_SIZE = 99.0
- COLOR_BLACK = [0.009, 0.006, 0.003, 1.0]
black ink
- COLOR_DARK_GREY = [0.309, 0.306, 0.303, 1.0]
dark grey ink
- COLOR_GREY = [0.509, 0.506, 0.503, 1.0]
grey ink
- COLOR_LIGHT_GREY = [0.699, 0.696, 0.693, 1.0]
light grey ink
- COLOR_WHITE = [0.999, 0.996, 0.993, 1.0]
white ink
- RELIEF_ANGLE_BEG = 69
beginning angle for ellipse drawings via
relief_colors()
- RELIEF_ANGLE_END = 249
ending angle for ellipse drawings via
relief_colors()
- THEME_DARK_BACKGROUND_COLOR = [0.009, 0.006, 0.003, 1.0]
dark theme background color in rgba(0.0 … 1.0)
- THEME_DARK_FONT_COLOR = [0.999, 0.996, 0.993, 1.0]
dark theme font color in rgba(0.0 … 1.0)
- THEME_LIGHT_BACKGROUND_COLOR = [0.999, 0.996, 0.993, 1.0]
light theme background color in rgba(0.0 … 1.0)
- THEME_LIGHT_FONT_COLOR = [0.009, 0.006, 0.003, 1.0]
light theme font color in rgba(0.0 … 1.0)
- THEME_SECTION_PREFIX = 'aeTheme_'
config-files section name prefix for to store app theme vars
- THEME_VARIABLE_PREFIX = 'MUSASV_'
mangle app state var names to not be interpreted as user-specific
- FLOW_KEY_SEP = ':'
separator character between flow action/object and flow key
- FLOW_ACTION_RE = re.compile('[a-z0-9]+')
regular expression detecting invalid characters in flow action string
- FLOW_OBJECT_RE = re.compile('[A-Za-z0-9_]+')
regular expression detecting invalid characters in flow object string
- APP_STATE_HELP_ID_PREFIX = 'help_app_state#'
message id prefix for app state change help texts
- FLOW_HELP_ID_PREFIX = 'help_flow#'
message id prefix for flow change help texts
- TOUR_PAGE_HELP_ID_PREFIX = 'tour_page#'
message id prefix of tour page text/dict
- TOUR_START_DELAY_DEF = 0.15
default value of tour start delay in seconds
- TOUR_EXIT_DELAY_DEF = 0.45
default value of tour exit delay in seconds
- PORTIONS_IMAGES = {'add_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/add_item.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/add_item.png')], 'app_tour': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/app_tour.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/app_tour.png')], 'bubble_arrow': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/bubble_arrow.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/bubble_arrow.png')], 'close_popup': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/close_popup.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/close_popup.png')], 'copy_node': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/copy_node.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/copy_node.png')], 'cut_node': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/cut_node.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/cut_node.png')], 'delete_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/delete_item.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/delete_item.png')], 'drag_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/drag_item.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/drag_item.png')], 'edit_font_size': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/enaml_app/img/edit_font_size.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/enaml_app/img/light_1/edit_font_size.png')], 'edit_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/edit_item.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/edit_item.png')], 'enter_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/enter_item.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/enter_item.png')], 'export_node': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/export_node.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/export_node.png')], 'filter_off': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/filter_off.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/filter_off.png')], 'filter_on': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/filter_on.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/filter_on.png')], 'flag_de': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/flag_de.png')], 'flag_en': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/flag_en.png')], 'flag_es': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/flag_es.png')], 'font_size': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/kivy_user_prefs/img/font_size.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/kivy_user_prefs/img/light_1/font_size.png')], 'help_circled': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/help_circled.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/help_circled.png')], 'help_icon': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/help_icon.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/help_icon.png')], 'icon_view': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/icon_view.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/icon_view.png')], 'import_node': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/import_node.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/import_node.png')], 'leave_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/leave_item.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/leave_item.png')], 'list_view': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/list_view.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/list_view.png')], 'open_node_info': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/open_node_info.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/open_node_info.png')], 'open_user_preferences': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/enaml_app/img/open_user_preferences.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/enaml_app/img/light_1/open_user_preferences.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/kivy_user_prefs/img/open_user_preferences.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/kivy_user_prefs/img/light_1/open_user_preferences.png')], 'paste_node': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/paste_node.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/paste_node.png')], 'save_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/save_item.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/save_item.png')], 'send_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/send_item.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/send_item.png')], 'sideloading_activate': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/kivy_sideloading/img/sideloading_activate.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/kivy_sideloading/img/light_1/sideloading_activate.png')], 'tap_pointer': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/tap_pointer.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/tap_pointer.png')], 'vibration': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/kivy_user_prefs/img/vibration.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/kivy_user_prefs/img/light_1/vibration.png')]}
app image files register
- PORTIONS_SOUNDS = {'added': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/added.wav')], 'debug_draw': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/debug_draw.wav')], 'debug_save': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/debug_save.wav')], 'deleted': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/deleted.wav')], 'edited': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/edited.wav')], 'enter_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/enter_item.wav')], 'error': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/error.wav')], 'filter_off': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/filter_off.wav')], 'filter_on': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/filter_on.wav')], 'leave_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/leave_item.wav')], 'touched': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/touched.wav')]}
app audio/sound files register
- REGISTERED_TOURS: dict[str, Type] = {'AnimatedOnboardingTour': <class 'ae.kivy.tours.AnimatedOnboardingTour'>, 'OnboardingTour': <class 'ae.gui.tours.OnboardingTour'>, 'SideloadingMenuTour': <class 'ae.kivy_sideloading.SideloadingMenuTour'>, 'TourDropdownFromButton': <class 'ae.gui.tours.TourDropdownFromButton'>, 'UserPreferencesTour': <class 'ae.gui.tours.UserPreferencesTour'>}
map(name: class) of all registered tour classes
- ColorOrInk
color or ink type
alias of
tuple[float,float,float] |list[float] |tuple[float,float,float,float]
- ReliefColors
tuple of top/bottom relief colors or empty tuple
alias of
tuple[tuple[float,float,float] |list[float],tuple[float,float,float] |list[float]] |tuple
- anchor_layout_x(anchor_spe, layout_width, win_width)[source]
calculate the anchor’s x position of the layout box.
- Parameters:
- Return type:
- Returns:
absolute x coordinate within the app window of anchor layout.
- anchor_layout_y(anchor_spe, layout_height, win_height)[source]
calculate the layout box y position of an anchor.
- anchor_points(font_size, anchor_spe)[source]
recalculate points of the anchor triangle drawing.
- Parameters:
- Return type:
- Returns:
6-item-tuple with the three x and y coordinates of the anchor triangle edges.
- anchor_spec(wid_x, wid_y, wid_width, wid_height, win_width, win_height)[source]
calculate anchor center pos (x, y) and anchor direction to the targeted widget.
- Parameters:
- Return type:
- Returns:
tooltip anchor specification tuple (
AnchorSpecType) with the three items:anchor_x (the absolute anchor center x-coordinate in the app main window),
anchor_y (the absolute anchor center y-coordinate in the app main window) and
anchor_dir (anchor direction: ‘r’=right, ‘i’=increase-y, ‘l’=left, ‘d’=decrease-y)
Note
the direction in the y-axis got named increase for higher y values and decrease for lower y values to support different coordinate systems of the GUI frameworks.
e.g., Kivy has the y-axis zero value at the bottom of the app window, whereas in enaml/Qt it is at the top.
- brighten_color(color_or_ink, factor=0.3)[source]
brightens the specified color/ink without changing an optionally passed alpha/occupancy value.
- Parameters:
color_or_ink¶ (
Union[tuple[float,float,float],list[float],tuple[float,float,float,float]]) – the color or ink to be brightened.factor¶ (
float) – the factor to brighten the color or ink by. its value must range between -1 and 1, 0 results in no brightening at all (original color), positive values are using the more complex HSV algorithm, and negative values the efficient RGB brightening algorithm. so +1 returns the brightest value of the specified color, whereas -1 results as white.
- Return type:
Union[tuple[float,float,float],list[float],tuple[float,float,float,float]]- Returns:
the brightened color or ink, as the same type as the input.
- color_from_hsv(hsv)[source]
convert HSV-color (H: 0-360, S: 0-1, V: 0-1) into its corresponding RGB color.
- complementary_color(color_or_ink, delta_h=180.0)[source]
determine the complementary color or ink without changing an optionally passed alpha/occupancy value.
- Parameters:
color_or_ink¶ (
Union[tuple[float,float,float],list[float],tuple[float,float,float,float]]) – the color or ink to convert into its complementary value.specify a value between -360 and +360 to get a complementary color. specify -180 or 180 to get the opposite value using the HSV algorithm, or a zero value to get the opposite color with the more efficient RGB algorithm. any other value will use the HSV algorithm, which adds this value as a delta angle in the HSV color circle. some harmonic delta angles are:
30: analogous colors
90, 180 and 270: tetradic colors 2, 3 and 4
120 and 240: triadic color 2 and 3
180: opposite color
- Return type:
Union[tuple[float,float,float],list[float],tuple[float,float,float,float]]- Returns:
the complementary color or ink, as the same type as the input. note that the HSV algorithm does not change any monochrom/greyscale colors; pass a zero value to the delta_h parameter to get an “opposite”-like color from a gray-scale color (see the unit tests on how the RGB algorithm does behave in relation to the HSV algorithm).
- darken_color(color_or_ink, factor=0.3)[source]
darkens the specified color/ink without changing an optionally passed alpha/occupancy value.
- Parameters:
color_or_ink¶ (
Union[tuple[float,float,float],list[float],tuple[float,float,float,float]]) – the color or ink to be darkened.factor¶ (
float) – the factor to darken the color or ink by. its value must range between -1 and 1, where 0 results in no darkening (original color), positive values are using the more complex HSV algorithm, and negative values the efficient RGB darkening algorithm. so +1 returns the darkest value of the specified color, whereas -1 results in a black color.
- Return type:
Union[tuple[float,float,float],list[float],tuple[float,float,float,float]]- Returns:
the darkened color or ink, as the same type as the input.
- ellipse_polar_radius(ell_a, ell_b, radian)[source]
calculate the radius from polar for the given ellipse and radian.
- ensure_tap_kwargs_refs(init_kwargs, tap_widget)[source]
ensure that the passed widget.__init__ kwargs dict contains a reference to itself within kwargs[‘tap_kwargs’].
- Parameters:
this alternative version is only 10 % faster but much less clean than the current implementation:
if 'tap_kwargs' not in init_kwargs: init_kwargs['tap_kwargs'] = {} tap_kwargs = init_kwargs['tap_kwargs'] if 'tap_widget' not in tap_kwargs: tap_kwargs['tap_widget'] = tap_widget if 'popup_kwargs' not in tap_kwargs: tap_kwargs['popup_kwargs'] = {} popup_kwargs = tap_kwargs['popup_kwargs'] if 'opener' not in popup_kwargs: popup_kwargs['opener'] = tap_kwargs['tap_widget']
- flow_change_confirmation_event_name(flow_id)[source]
determine the name of the event method for the change confirmation of the passed flow_id.
- flow_class_name(flow_id, name_suffix)[source]
determine the class name for the given flow id and class name suffix.
- flow_path_id(flow_path, path_index=-1)[source]
determine the flow id of the newest/last entry in the flow_path.
- flow_path_strip(flow_path)[source]
return a copy of the specified flow_path with all non-enter actions stripped from the end.
- flow_popup_class_name(flow_id)[source]
determine the name of the Popup class for the given flow id.
- help_id_tour_class(help_id)[source]
determine the tour class if passed help id has attached tour pages.
- help_sub_id(help_id)[source]
determine sub id (flow id, tour id or app state name) of the current/specified/passed help id.
opposite of
id_of_flow_help()/id_of_state_help()/id_of_tour_help().
- merge_popups_to_close(tap_kwargs, add_kwargs)[source]
merge the popups_to_close item values of the two specified tap_kwargs dicts.
- Parameters:
- Return type:
- Returns:
either tuple with the merged popup widgets (ensuring to have no duplicates), or an integer with the number of popups to close, or an empty tuple if both parameters do not have a popups_to_close key.
- Raises:
AssertionError – if the types of the popups_to_close values are not matching.
- popup_event_kwargs(message, title, confirm_flow_id=None, confirm_kwargs=None, confirm_text=None, **popup_kwargs)[source]
type-check and bundle args of the MainAppClass.show_*() methods into a single event kwargs dict for a FlowPopup.
- Parameters:
confirm_flow_id¶ (
Optional[str]) – tap_flow_id of the popup’s ‘confirm’ button.confirm_kwargs¶ (
Optional[dict[str,Any]]) – tap_kwargs event args of the popup’s ‘confirm’ button.confirm_text¶ (
Optional[str]) – popup confirmation button text. if empty, then the i18n translation of “confirm” is used.popup_kwargs¶ – any other extra popup kwargs (not type checked).
- Return type:
- Returns:
dict with at least a ‘popup_kwargs’ key to be passed as event_kwargs argument to the
change_flow()method.
- register_package_images()[source]
call from the module scope of the package to register/add the image/img resources path.
no parameters needed because we use here
stack_var()helper function to determine the module file path via the __file__ module variable of the caller module in the call stack. in this call we have to overwrite the default value (SKIPPED_MODULES) of theskip_modulesparameter to not skip ae portions that are providing package resources and are listed in theSKIPPED_MODULES, like e.g.,ae.gui.appandae.gui.utils(passing empty string ‘’ to overwrite the default skip list).
- register_package_sounds()[source]
call from the module scope of the package to register/add sound file resources.
no parameters needed because we use here
stack_var()helper function to determine the module file path via the __file__ module variable of the caller module in the call stack. in this call, we have to overwrite the default value (SKIPPED_MODULES) of theskip_modulesparameter to not skip ae portions that are providing package resources and are listed in theSKIPPED_MODULES.
- relief_colors(color_or_ink=None, top_factor=0.6, bottom_factor=0.3, sunken=False)[source]
calculate the top-left and bottom-right colors used for square/ellipse relief effects.
- Parameters:
color_or_ink¶ (
Union[tuple[float,float,float],list[float],tuple[float,float,float,float],None]) – optional color used to calculate the relief colors from. if not specified, then theCOLOR_GREYconstant will be used to draw the relief effect.top_factor¶ (
float) – factor to brighten/darken the top-left part of a square/ellipse with a relief effect, via the HSV calculation method. pass a negative factor to use the more efficient RGB method.bottom_factor¶ (
float) – factor to brighten/darken the bottom part of a square/ellipse with a relief effect, via tbe HSV calculation method. pass a negative factor to use the more efficient RGB method.sunken¶ (
bool) – if True, then the top-left part of the relief colors will be darkened instead of brightened. a raised relief effect will be produced if False (default).
- Return type:
Union[tuple[Union[tuple[float,float,float],list[float]],Union[tuple[float,float,float],list[float]]],tuple]- Returns:
tuple with the brightened/darkened top and bottom colors, calculated from the argument specified in
color_or_ink, or an empty tuple if the alpha value ofcolor_or_inkis zero.
- tour_help_translation(page_id)[source]
determine help translation for the passed page id (flow id or app state name).
- update_tap_kwargs(widget_or_kwargs, popup_kwargs=None, **tap_kwargs)[source]
update or simulate a widget’s tap_kwargs property and return the updated dictionary (for kv rule of tap_kwargs).
- Parameters:
widget_or_kwargs¶ (
Union[dict[str,Any],Any]) – either the tap widget (with optional tap_kwargs property, to be extended), or a tap_kwargs dict to be updated (returning an extended shallow copy of it).popup_kwargs¶ (
Optional[dict[str,Any]]) – dict with items to update popup_kwargs key of.tap_kwargs¶ – additional tap_kwargs items to update.
- Return type:
- Returns:
tap_kwargs dict extended with the specified argument values. if the
widgetparameter is a widget, then the ‘opener’ and ‘tap_widget’ keys will be set to this widget if they are not already set. if thetap_kwargsparameter as well as widget.tap_kwargs are having the key ‘popups_to_close’, then both values will be returned merged.
- module_globals = {'APP_STATE_HELP_ID_PREFIX': 'help_app_state#', 'APP_STATE_SECTION_NAME': 'aeAppState', 'APP_STATE_VERSION_VAR_NAME': 'app_state_version', 'AnchorSpecType': tuple[float, float, str], 'Any': typing.Any, 'AppStatesType': dict[str, typing.Any], 'COLOR_BLACK': [0.009, 0.006, 0.003, 1.0], 'COLOR_DARK_GREY': [0.309, 0.306, 0.303, 1.0], 'COLOR_GREY': [0.509, 0.506, 0.503, 1.0], 'COLOR_LIGHT_GREY': [0.699, 0.696, 0.693, 1.0], 'COLOR_WHITE': [0.999, 0.996, 0.993, 1.0], 'Callable': typing.Callable, 'ColorOrInk': typing.Union[tuple[float, float, float], list[float], tuple[float, float, float, float]], 'ColorRGB': typing.Union[tuple[float, float, float], list[float]], 'ColorRGBA': typing.Union[tuple[float, float, float, float], list[float]], 'EventKwargsType': dict[str, typing.Any], 'ExplainedMatcherType': typing.Union[typing.Callable[[typing.Any], bool], str], 'FLOW_ACTION_RE': re.compile('[a-z0-9]+'), 'FLOW_HELP_ID_PREFIX': 'help_flow#', 'FLOW_KEY_SEP': ':', 'FLOW_OBJECT_RE': re.compile('[A-Za-z0-9_]+'), 'FilesRegister': <class 'ae.paths.FilesRegister'>, 'HelpVarsType': dict[str, typing.Any], 'MAX_FONT_SIZE': 99.0, 'MIN_FONT_SIZE': 15.0, 'NAME_PARTS_SEP': '_', 'Optional': typing.Optional, 'PORTIONS_IMAGES': {'add_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/add_item.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/add_item.png')], 'app_tour': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/app_tour.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/app_tour.png')], 'bubble_arrow': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/bubble_arrow.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/bubble_arrow.png')], 'close_popup': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/close_popup.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/close_popup.png')], 'copy_node': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/copy_node.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/copy_node.png')], 'cut_node': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/cut_node.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/cut_node.png')], 'delete_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/delete_item.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/delete_item.png')], 'drag_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/drag_item.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/drag_item.png')], 'edit_font_size': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/enaml_app/img/edit_font_size.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/enaml_app/img/light_1/edit_font_size.png')], 'edit_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/edit_item.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/edit_item.png')], 'enter_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/enter_item.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/enter_item.png')], 'export_node': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/export_node.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/export_node.png')], 'filter_off': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/filter_off.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/filter_off.png')], 'filter_on': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/filter_on.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/filter_on.png')], 'flag_de': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/flag_de.png')], 'flag_en': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/flag_en.png')], 'flag_es': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/flag_es.png')], 'font_size': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/kivy_user_prefs/img/font_size.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/kivy_user_prefs/img/light_1/font_size.png')], 'help_circled': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/help_circled.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/help_circled.png')], 'help_icon': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/help_icon.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/help_icon.png')], 'icon_view': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/icon_view.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/icon_view.png')], 'import_node': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/import_node.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/import_node.png')], 'leave_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/leave_item.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/leave_item.png')], 'list_view': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/list_view.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/list_view.png')], 'open_node_info': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/open_node_info.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/open_node_info.png')], 'open_user_preferences': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/enaml_app/img/open_user_preferences.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/enaml_app/img/light_1/open_user_preferences.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/kivy_user_prefs/img/open_user_preferences.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/kivy_user_prefs/img/light_1/open_user_preferences.png')], 'paste_node': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/paste_node.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/paste_node.png')], 'save_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/save_item.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/save_item.png')], 'send_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/send_item.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/send_item.png')], 'sideloading_activate': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/kivy_sideloading/img/sideloading_activate.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/kivy_sideloading/img/light_1/sideloading_activate.png')], 'tap_pointer': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/tap_pointer.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/img/light_1/tap_pointer.png')], 'vibration': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/kivy_user_prefs/img/vibration.png'), RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/kivy_user_prefs/img/light_1/vibration.png')]}, 'PORTIONS_SOUNDS': {'added': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/added.wav')], 'debug_draw': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/debug_draw.wav')], 'debug_save': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/debug_save.wav')], 'deleted': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/deleted.wav')], 'edited': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/edited.wav')], 'enter_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/enter_item.wav')], 'error': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/error.wav')], 'filter_off': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/filter_off.wav')], 'filter_on': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/filter_on.wav')], 'leave_item': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/leave_item.wav')], 'touched': [RegisteredFile('/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/snd/touched.wav')]}, 'PopupsToCloseType': typing.Union[int, tuple], 'REGISTERED_TOURS': {'AnimatedOnboardingTour': <class 'ae.kivy.tours.AnimatedOnboardingTour'>, 'OnboardingTour': <class 'ae.gui.tours.OnboardingTour'>, 'SideloadingMenuTour': <class 'ae.kivy_sideloading.SideloadingMenuTour'>, 'TourDropdownFromButton': <class 'ae.gui.tours.TourDropdownFromButton'>, 'UserPreferencesTour': <class 'ae.gui.tours.UserPreferencesTour'>}, 'RELIEF_ANGLE_BEG': 69, 'RELIEF_ANGLE_END': 249, 'ReliefColors': typing.Union[tuple[typing.Union[tuple[float, float, float], list[float]], typing.Union[tuple[float, float, float], list[float]]], tuple], 'THEME_DARK_BACKGROUND_COLOR': [0.009, 0.006, 0.003, 1.0], 'THEME_DARK_FONT_COLOR': [0.999, 0.996, 0.993, 1.0], 'THEME_LIGHT_BACKGROUND_COLOR': [0.999, 0.996, 0.993, 1.0], 'THEME_LIGHT_FONT_COLOR': [0.009, 0.006, 0.003, 1.0], 'THEME_SECTION_PREFIX': 'aeTheme_', 'THEME_VARIABLE_PREFIX': 'MUSASV_', 'TOUR_EXIT_DELAY_DEF': 0.45, 'TOUR_PAGE_HELP_ID_PREFIX': 'tour_page#', 'TOUR_START_DELAY_DEF': 0.15, 'Type': typing.Type, 'Union': typing.Union, '__annotations__': {'REGISTERED_TOURS': dict[str, typing.Type]}, '__builtins__': {'ArithmeticError': <class 'ArithmeticError'>, 'AssertionError': <class 'AssertionError'>, 'AttributeError': <class 'AttributeError'>, 'BaseException': <class 'BaseException'>, 'BaseExceptionGroup': <class 'BaseExceptionGroup'>, 'BlockingIOError': <class 'BlockingIOError'>, 'BrokenPipeError': <class 'BrokenPipeError'>, 'BufferError': <class 'BufferError'>, 'BytesWarning': <class 'BytesWarning'>, 'ChildProcessError': <class 'ChildProcessError'>, 'ConnectionAbortedError': <class 'ConnectionAbortedError'>, 'ConnectionError': <class 'ConnectionError'>, 'ConnectionRefusedError': <class 'ConnectionRefusedError'>, 'ConnectionResetError': <class 'ConnectionResetError'>, 'DeprecationWarning': <class 'DeprecationWarning'>, 'EOFError': <class 'EOFError'>, 'Ellipsis': Ellipsis, 'EncodingWarning': <class 'EncodingWarning'>, 'EnvironmentError': <class 'OSError'>, 'Exception': <class 'Exception'>, 'ExceptionGroup': <class 'ExceptionGroup'>, 'False': False, 'FileExistsError': <class 'FileExistsError'>, 'FileNotFoundError': <class 'FileNotFoundError'>, 'FloatingPointError': <class 'FloatingPointError'>, 'FutureWarning': <class 'FutureWarning'>, 'GeneratorExit': <class 'GeneratorExit'>, 'IOError': <class 'OSError'>, 'ImportError': <class 'ImportError'>, 'ImportWarning': <class 'ImportWarning'>, 'IndentationError': <class 'IndentationError'>, 'IndexError': <class 'IndexError'>, 'InterruptedError': <class 'InterruptedError'>, 'IsADirectoryError': <class 'IsADirectoryError'>, 'KeyError': <class 'KeyError'>, 'KeyboardInterrupt': <class 'KeyboardInterrupt'>, 'LookupError': <class 'LookupError'>, 'MemoryError': <class 'MemoryError'>, 'ModuleNotFoundError': <class 'ModuleNotFoundError'>, 'NameError': <class 'NameError'>, 'None': None, 'NotADirectoryError': <class 'NotADirectoryError'>, 'NotImplemented': NotImplemented, 'NotImplementedError': <class 'NotImplementedError'>, 'OSError': <class 'OSError'>, 'OverflowError': <class 'OverflowError'>, 'PendingDeprecationWarning': <class 'PendingDeprecationWarning'>, 'PermissionError': <class 'PermissionError'>, 'ProcessLookupError': <class 'ProcessLookupError'>, 'RecursionError': <class 'RecursionError'>, 'ReferenceError': <class 'ReferenceError'>, 'ResourceWarning': <class 'ResourceWarning'>, 'RuntimeError': <class 'RuntimeError'>, 'RuntimeWarning': <class 'RuntimeWarning'>, 'StopAsyncIteration': <class 'StopAsyncIteration'>, 'StopIteration': <class 'StopIteration'>, 'SyntaxError': <class 'SyntaxError'>, 'SyntaxWarning': <class 'SyntaxWarning'>, 'SystemError': <class 'SystemError'>, 'SystemExit': <class 'SystemExit'>, 'TabError': <class 'TabError'>, 'TimeoutError': <class 'TimeoutError'>, 'True': True, 'TypeError': <class 'TypeError'>, 'UnboundLocalError': <class 'UnboundLocalError'>, 'UnicodeDecodeError': <class 'UnicodeDecodeError'>, 'UnicodeEncodeError': <class 'UnicodeEncodeError'>, 'UnicodeError': <class 'UnicodeError'>, 'UnicodeTranslateError': <class 'UnicodeTranslateError'>, 'UnicodeWarning': <class 'UnicodeWarning'>, 'UserWarning': <class 'UserWarning'>, 'ValueError': <class 'ValueError'>, 'Warning': <class 'Warning'>, 'ZeroDivisionError': <class 'ZeroDivisionError'>, '__annotations__': {}, '__build_class__': <built-in function __build_class__>, '__debug__': True, '__doc__': "Built-in functions, types, exceptions, and other objects.\n\nThis module provides direct access to all 'built-in'\nidentifiers of Python; for example, builtins.len is\nthe full name for the built-in function len().\n\nThis module is not normally accessed explicitly by most\napplications, but can be useful in modules that provide\nobjects with the same name as a built-in value, but in\nwhich the built-in of that name is also needed.", '__import__': <built-in function __import__>, '__loader__': <class '_frozen_importlib.BuiltinImporter'>, '__name__': 'builtins', '__package__': '', '__spec__': ModuleSpec(name='builtins', loader=<class '_frozen_importlib.BuiltinImporter'>, origin='built-in'), 'abs': <built-in function abs>, 'aiter': <built-in function aiter>, 'all': <built-in function all>, 'anext': <built-in function anext>, 'any': <built-in function any>, 'ascii': <built-in function ascii>, 'bin': <built-in function bin>, 'bool': <class 'bool'>, 'breakpoint': <built-in function breakpoint>, 'bytearray': <class 'bytearray'>, 'bytes': <class 'bytes'>, 'callable': <built-in function callable>, 'chr': <built-in function chr>, 'classmethod': <class 'classmethod'>, 'compile': <built-in function compile>, 'complex': <class 'complex'>, 'copyright': Copyright (c) 2001-2023 Python Software Foundation. All Rights Reserved. Copyright (c) 2000 BeOpen.com. All Rights Reserved. Copyright (c) 1995-2001 Corporation for National Research Initiatives. All Rights Reserved. Copyright (c) 1991-1995 Stichting Mathematisch Centrum, Amsterdam. All Rights Reserved., 'credits': Thanks to CWI, CNRI, BeOpen, Zope Corporation, the Python Software Foundation, and a cast of thousands for supporting Python development. See www.python.org for more information., 'delattr': <built-in function delattr>, 'dict': <class 'dict'>, 'dir': <built-in function dir>, 'divmod': <built-in function divmod>, 'enumerate': <class 'enumerate'>, 'eval': <built-in function eval>, 'exec': <built-in function exec>, 'exit': Use exit() or Ctrl-D (i.e. EOF) to exit, 'filter': <class 'filter'>, 'float': <class 'float'>, 'format': <built-in function format>, 'frozenset': <class 'frozenset'>, 'getattr': <built-in function getattr>, 'globals': <built-in function globals>, 'hasattr': <built-in function hasattr>, 'hash': <built-in function hash>, 'help': Type help() for interactive help, or help(object) for help about object., 'hex': <built-in function hex>, 'id': <built-in function id>, 'input': <built-in function input>, 'int': <class 'int'>, 'isinstance': <built-in function isinstance>, 'issubclass': <built-in function issubclass>, 'iter': <built-in function iter>, 'len': <built-in function len>, 'license': Type license() to see the full license text, 'list': <class 'list'>, 'locals': <built-in function locals>, 'map': <class 'map'>, 'max': <built-in function max>, 'memoryview': <class 'memoryview'>, 'min': <built-in function min>, 'next': <built-in function next>, 'object': <class 'object'>, 'oct': <built-in function oct>, 'open': <built-in function open>, 'ord': <built-in function ord>, 'pow': <built-in function pow>, 'print': <built-in function print>, 'property': <class 'property'>, 'quit': Use quit() or Ctrl-D (i.e. EOF) to exit, 'range': <class 'range'>, 'repr': <built-in function repr>, 'reversed': <class 'reversed'>, 'round': <built-in function round>, 'set': <class 'set'>, 'setattr': <built-in function setattr>, 'slice': <class 'slice'>, 'sorted': <built-in function sorted>, 'staticmethod': <class 'staticmethod'>, 'str': <class 'str'>, 'sum': <built-in function sum>, 'super': <class 'super'>, 'tuple': <class 'tuple'>, 'type': <class 'type'>, 'vars': <built-in function vars>, 'zip': <class 'zip'>}, '__cached__': '/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/__pycache__/utils.cpython-312.pyc', '__doc__': '\nGUI app constants and helper functions\n--------------------------------------\n', '__file__': '/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/utils.py', '__loader__': <_frozen_importlib_external.SourceFileLoader object>, '__name__': 'ae.gui.utils', '__package__': 'ae.gui', '__spec__': ModuleSpec(name='ae.gui.utils', loader=<_frozen_importlib_external.SourceFileLoader object>, origin='/home/docs/checkouts/readthedocs.org/user_builds/ae/envs/latest/lib/python3.12/site-packages/ae/gui/utils.py'), '_d_': ('linux', <function path_name>, <function placeholder_path>), 'anchor_layout_x': <function anchor_layout_x>, 'anchor_layout_y': <function anchor_layout_y>, 'anchor_points': <function anchor_points>, 'anchor_spec': <function anchor_spec>, 'brighten_color': <function brighten_color>, 'color_from_hsv': <function color_from_hsv>, 'color_to_hsv': <function color_to_hsv>, 'complementary_color': <function complementary_color>, 'cos': <built-in function cos>, 'darken_color': <function darken_color>, 'ellipse_polar_radius': <function ellipse_polar_radius>, 'ensure_tap_kwargs_refs': <function ensure_tap_kwargs_refs>, 'flow_action': <function flow_action>, 'flow_action_split': <function flow_action_split>, 'flow_change_confirmation_event_name': <function flow_change_confirmation_event_name>, 'flow_class_name': <function flow_class_name>, 'flow_key': <function flow_key>, 'flow_key_split': <function flow_key_split>, 'flow_object': <function flow_object>, 'flow_path_id': <function flow_path_id>, 'flow_path_strip': <function flow_path_strip>, 'flow_popup_class_name': <function flow_popup_class_name>, 'get_text': <function get_text>, 'help_id_tour_class': <function help_id_tour_class>, 'help_sub_id': <function help_sub_id>, 'id_of_flow': <function id_of_flow>, 'id_of_flow_help': <function id_of_flow_help>, 'id_of_state_help': <function id_of_state_help>, 'id_of_tour_help': <function id_of_tour_help>, 'merge_popups_to_close': <function merge_popups_to_close>, 'mix_colors': <function mix_colors>, 'module_globals': dict(...), 'norm_path': <function norm_path>, 'os_path_dirname': <function dirname>, 'os_path_join': <function join>, 'os_platform': 'linux', 'path_name': <function path_name>, 'placeholder_path': <function placeholder_path>, 'popup_event_kwargs': <function popup_event_kwargs>, 're': <module 're' from '/home/docs/.asdf/installs/python/3.12.12/lib/python3.12/re/__init__.py'>, 'register_package_images': <function register_package_images>, 'register_package_sounds': <function register_package_sounds>, 'relief_colors': <function relief_colors>, 'replace_flow_action': <function replace_flow_action>, 'sin': <built-in function sin>, 'snake_to_camel': <function snake_to_camel>, 'sqrt': <built-in function sqrt>, 'stack_var': <function stack_var>, 'tour_help_translation': <function tour_help_translation>, 'tour_id_class': <function tour_id_class>, 'translation': <function translation>, 'translation_short_help_id': <function translation_short_help_id>, 'update_tap_kwargs': <function update_tap_kwargs>, 'widget_page_id': <function widget_page_id>}
used. e.g., for execution/evaluation of dynamic code, expressions and f-strings of the app tour and help systems