Unify configs so we can get rid of all those branches per machine. Also Wayland changes for Violet
This commit is contained in:
parent
5a0041e7d5
commit
6dd362247e
10 changed files with 274 additions and 105 deletions
17
kuro/base.py
17
kuro/base.py
|
@ -1,3 +1,5 @@
|
|||
import time
|
||||
|
||||
from libqtile import layout as libqtile_layout, layout, bar, widget
|
||||
from libqtile.lazy import lazy
|
||||
from libqtile.config import Key, Group, Screen, Drag, Click, Match
|
||||
|
@ -7,13 +9,21 @@ from libqtile.log_utils import logger
|
|||
|
||||
|
||||
class BaseConfig:
|
||||
config_name = "KuroBase"
|
||||
|
||||
@classmethod
|
||||
def get(cls, key, default):
|
||||
if hasattr(cls, key):
|
||||
return cls.__dict__[key]
|
||||
return getattr(cls, key)
|
||||
#return cls.__dict__[key]
|
||||
else:
|
||||
return default
|
||||
|
||||
@classmethod
|
||||
def initialize(cls, qtile):
|
||||
# Can do extra initialization based on qtile instance here
|
||||
pass
|
||||
|
||||
|
||||
class BaseTheme:
|
||||
# Changing variables initialized by function
|
||||
|
@ -45,7 +55,7 @@ class BaseTheme:
|
|||
auto_fullscreen = True
|
||||
focus_on_window_activation = "smart"
|
||||
extensions = []
|
||||
reconfigure_screens = True
|
||||
reconfigure_screens = False
|
||||
|
||||
# XXX: Gasp! We're lying here. In fact, nobody really uses or cares about this
|
||||
# string besides java UI toolkits; you can see several discussions on the
|
||||
|
@ -60,6 +70,9 @@ class BaseTheme:
|
|||
# 'export _JAVA_AWT_WM_NONREPARENTING=1'
|
||||
wmname = "LG3D"
|
||||
|
||||
def __init__(self):
|
||||
self.startup_time = time.time()
|
||||
|
||||
def initialize(self):
|
||||
logger.info("Initializing widget defaults...")
|
||||
self.widget_defaults = self.init_widget_defaults()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue