molsysviewer.config package#

Submodules#

molsysviewer.config.user_presets module#

molsysviewer.config.user_presets.load_user_presets(path)[source]#

Load user presets from a JSON or YAML file into user_presets.

The file must contain a top-level mapping: preset_name -> {base, options, rules}. YAML support requires pyyaml; falls back to JSON otherwise.

Parameters:

path (str | Path)

Return type:

Dict[str, Dict[str, Any]]

molsysviewer.config.user_presets.user_presets: Dict[str, Dict[str, Any]] = {}#

Registry of user-defined representation presets.

The registry is a mapping: preset_name -> configuration dict. Each configuration typically contains base, optional options, and a list of rules (by selection or atom indices).

See load_user_presets() for the expected file structure.

Module contents#

User-facing configuration for MolSysViewer.

Adjust the values here to control default viewer behavior without editing code.

molsysviewer.config.load_user_presets(path)[source]#

Load user presets from a JSON or YAML file into user_presets.

The file must contain a top-level mapping: preset_name -> {base, options, rules}. YAML support requires pyyaml; falls back to JSON otherwise.

Parameters:

path (str | Path)

Return type:

Dict[str, Dict[str, Any]]

molsysviewer.config.set_default_quantities_form(form='pint')[source]#
molsysviewer.config.set_default_quantities_parser(form='pint')[source]#
molsysviewer.config.set_default_standard_units(standards=['nm', 'ps', 'K', 'mole', 'amu', 'e', 'kJ/mol', 'kJ/(mol*nm**2)', 'N', 'degrees'])[source]#