Skip to content

Preferences

russ_hensel edited this page Jul 1, 2025 · 7 revisions

A very large amount of application behavior is managed through preferences in preferences.py The basic idea is simple: we have a global singleton that has instance variables which are then use elsewhere in the program.

we will briefly discuss two aspects of this:

  • some useful parameters or groups of parameters
  • some complications in the object

Some useful parameters or groups of parameters As usual in the application you should read the code, only the highest level explanation is in this Wiki.

  • Variables that control what tabs you see:

    • dir_for_tabs
    • min_complete
    • default_search = "qq"
    • do_search_on_init = True
  • Logging

    • self.logging_level = logging.INFO

    • pylogging_fn file name for the python logging

    • log_mode controls if you get a new log on each startup

    • logger_id an id in the log file

  • Application appearance

    • qt_width controls size of app

    • qt_height

    • ...

    • wat_qt_width controls size of wat inspector

    • wat_qt_height 0

    • ...

  • External Editor

    • text_editor name of system editor

Some complications in the object

  • init() at bottom of file because generally should not be changed

  • mode_default() sets up a default mode that should minimally work for everyone ( on linux ). It's values may be overwritten by modes you invoke in choose_mode()External Editor

  • mode_new_user() a mode that a new user may want to customize for them selves.

  • more i shoud document

  • choose_mode() at top because may be changed often by user -- chooses a mode for the application

    • text_editor name of system editor

Clone this wiki locally