Class: QgsSettingsEntryInteger¶
- class qgis.core.QgsSettingsEntryInteger¶
Bases:
QgsSettingsEntryBaseTemplateintBase
An integer settings entry.
New in version 3.20.
QgsSettingsEntryInteger(name: str, parent:
QgsSettingsTreeNode
, defaultValue: int = 0, description: str = ‘’, options: Union[Qgis.SettingsOptions, Qgis.SettingsOption] = Qgis.SettingsOptions(), minValue: int = INT_MIN, maxValue: int = INT_MAX) Constructor for QgsSettingsEntryInteger.- Parameters:
name – specifies the name of the setting.
parent – specifies the parent in the tree of settings.
defaultValue – specifies the default value for the settings entry.
description – specifies a description for the settings entry.
options – specifies the options for the settings entry.
minValue – specifies the minimal value.
maxValue – specifies the maximal value.
QgsSettingsEntryInteger(key: str, pluginName: str, defaultValue: int = 0, description: str = ‘’, options: Union[Qgis.SettingsOptions, Qgis.SettingsOption] = Qgis.SettingsOptions(), minValue: int = INT_MIN, maxValue: int = INT_MAX) Constructor for QgsSettingsEntryInteger. This constructor is intended to be used from plugins.
- Parameters:
key – specifies the key of the settings.
pluginName – is used to define the key of the setting
defaultValue – specifies the default value for the settings entry.
description – specifies a description for the settings entry.
options – specifies the options for the settings entry.
minValue – specifies the minimal value.
maxValue – specifies the maximal value.
QgsSettingsEntryInteger(
QgsSettingsEntryInteger
)Methods
Check if the value is valid
- param value:
Converts the value to a variant
Returns the maximum value.
Returns the minimum value.
Sets the settings value with an optional list of dynamic parts
- rtype:
Qgis.SettingsType
- checkValuePrivate(self, value: int) bool ¶
Check if the value is valid
- convertFromVariant(self, value: Any) int ¶
- Parameters:
value (Any) –
- Return type:
int
- convertToVariant(self, value: int) Any ¶
Converts the value to a variant
- maxValue(self) int ¶
Returns the maximum value.
- Return type:
int
- minValue(self) int ¶
Returns the minimum value.
- Return type:
int
- setValuePrivate(self, value: int, dynamicKeyPartList: Iterable[str]) bool ¶
Sets the settings value with an optional list of dynamic parts
- settingsType(self) Qgis.SettingsType ¶
- Return type: