dicogis.ui.wdg_settings module

Name: SettingsWidget Purpose: Form of the settings of DicoGIS, shown in the settings dialog.

Author: Julien Moura (@geojulien)

class dicogis.ui.wdg_settings.SettingsWidget(parent=None)

Bases: QWidget

Form of the end-user settings, shown by the settings dialog.

__init__(parent=None)

Initializes the form of the end-user options.

Parameters:

parent (QWidget | None) – Qt parent widget

apply_debug_logging(enabled)

Toggle root logger verbosity immediately.

Parameters:

enabled (bool) – whether debug (verbose) logging should be enabled.

Return type:

None

apply_ui_style(style_name)

Apply the selected Qt style immediately to the running application.

Parameters:

style_name (str) – name of a Qt style, as listed by QStyleFactory.keys().

Return type:

None

get_listing_scan_kwargs()

Return parallel_scan/max_workers kwargs ready for find_geodata_files() (translating the spinbox’s 0 = ‘Auto’ into the None that find_geodata_files() expects).

Return type:

dict

get_publish_timeout()

Return how long to wait for a catalog.

Return type:

float

Returns:

timeout, in seconds

get_settings()

Return the settings, as shown.

Return type:

dict[str, bool | int | str]

Returns:

setting -> value

get_ui_options()

Return interface options as a dict.

Return type:

dict

imposed_settings()

Settings imposed by an environment variable: not to be saved.

Return type:

frozenset[str]

Returns:

keys of the settings, style for the interface style

retranslate_ui()

Update widgets texts for the currently active language.

Return type:

None

set_settings(values)

Show settings, from options.ini or saved before an edit. The ones imposed by an environment variable keep its value.

Parameters:

values (dict) – setting -> value; unknown settings are ignored

Return type:

None

set_ui_options(values)

Apply interface options from a dict, unless imposed by the environment.

Return type:

None