# sec_interp.core.config module

Configuration Service Module.

Provides a centralized way to manage plugin settings using QgsSettings.

class sec_interp.core.config.ConfigService

  Bases: `object`

  Service to handle plugin configuration and persistent settings.

  Initialize the Configuration Service with QgsSettings.

  PREFIX = '/SecInterp/'
  DEFAULTS = {'auto_lod': True, 'buffer_dist': 100.0, 'dip_scale_factor': 1.0, 'dpi': 300, 'export_quality': 95, 'last_output_dir': '', 'max_preview_points': 10000, 'preview_height': 600, 'preview_width': 800, 'sampling_interval': 10.0, 'scale': 500.0, 'vert_exag': 1.0}
  SUPPORTED_IMAGE_FORMATS = ['.png', '.jpg', '.jpeg']
  SUPPORTED_VECTOR_FORMATS = ['.shp']
  SUPPORTED_DOCUMENT_FORMATS = ['.pdf', '.svg']
  __init__()

    Initialize the Configuration Service with QgsSettings.

  get(key: str, default: Any = None) → Any

    Retrieve a configuration value by key.

    Parameters:

      - key – The configuration key (without prefix).

      - default – Optional default value if not found in settings or defaults.

    Returns:

      The configuration value from settings or its default value.

  set(key: str, value: Any) → None

    Store a configuration value.

    Parameters:

      - key – The configuration key (without prefix).

      - value – The value to persist in settings.

  reset_defaults() → None

    Reset all known persistent settings to their default values.