Configuration Handling (config.py
)¶
Configuration parsing code
- KEYLOOKUP = {'+': 'plus', ',': 'comma', '-': 'minus', '.': 'period'}¶
Used for resolving certain keysyms
- load_config(path)[source]¶
Load the config file from the given path, applying fixes as needed. If it does not exist, create it from the configuration defaults.
DEFAULTS
{ 'general': { 'ColumnCount': 3,
'MarginX_Percent': 0,
'MarginY_Percent': 0,
'ModMask': '<Ctrl><Alt>',
'MovementsWrap': True},
'keys': { '<Shift>KP_1': 'move-to-bottom-left',
'<Shift>KP_2': 'move-to-bottom',
'<Shift>KP_3': 'move-to-bottom-right',
'<Shift>KP_4': 'move-to-left',
'<Shift>KP_5': 'move-to-center',
'<Shift>KP_6': 'move-to-right',
'<Shift>KP_7': 'move-to-top-left',
'<Shift>KP_8': 'move-to-top',
'<Shift>KP_9': 'move-to-top-right',
'C': 'move-to-center',
'H': 'horizontal-maximize',
'KP_0': 'maximize',
'KP_1': 'bottom-left',
'KP_2': 'bottom',
'KP_3': 'bottom-right',
'KP_4': 'left',
'KP_5': 'center',
'KP_6': 'right',
'KP_7': 'top-left',
'KP_8': 'top',
'KP_9': 'top-right',
'KP_Enter': 'monitor-switch',
'V': 'vertical-maximize'}}