Added transparancy toggle setting; changed default layout
This commit is contained in:
parent
23c2a99c7d
commit
72b70d28b5
@ -24,7 +24,7 @@ class BaseContainer(Gtk.Box):
|
||||
|
||||
|
||||
def _setup_styling(self):
|
||||
self.set_orientation(1)
|
||||
self.set_orientation(Gtk.Orientation.VERTICAL)
|
||||
|
||||
def _setup_signals(self):
|
||||
...
|
||||
|
@ -55,6 +55,9 @@ class Controller(DummyMixin, SignalsMixins, ControllerData):
|
||||
event_system.subscribe("handle_dir_from_ipc", self.handle_dir_from_ipc)
|
||||
event_system.subscribe("tggl_top_main_menubar", self._tggl_top_main_menubar)
|
||||
|
||||
def _tggl_top_main_menubar(self):
|
||||
print("_tggl_top_main_menubar > stub...")
|
||||
|
||||
def setup_builder_and_container(self):
|
||||
self.builder = Gtk.Builder()
|
||||
self.builder.add_from_file(settings.get_glade_file())
|
||||
@ -67,6 +70,3 @@ class Controller(DummyMixin, SignalsMixins, ControllerData):
|
||||
|
||||
def get_base_container(self):
|
||||
return self.base_container
|
||||
|
||||
def _tggl_top_main_menubar(self):
|
||||
print("_tggl_top_main_menubar > stub...")
|
||||
|
@ -70,7 +70,7 @@ class Window(Gtk.ApplicationWindow):
|
||||
screen = self.get_screen()
|
||||
visual = screen.get_rgba_visual()
|
||||
|
||||
if visual != None and screen.is_composited():
|
||||
if visual and screen.is_composited() and settings.make_transparent() == 0:
|
||||
self.set_visual(visual)
|
||||
self.set_app_paintable(True)
|
||||
self.connect("draw", self._area_draw)
|
||||
|
@ -36,6 +36,18 @@ class Settings(StartCheckMixin, Singleton):
|
||||
self._CONTEXT_MENU = f"{self._HOME_CONFIG_PATH}/contexct_menu.json"
|
||||
self._WINDOW_ICON = f"{self._DEFAULT_ICONS}/{app_name.lower()}.png"
|
||||
|
||||
# self._USR_CONFIG_FILE = f"{self._USR_PATH}/settings.json"
|
||||
# self._PLUGINS_PATH = f"plugins"
|
||||
# self._CONFIG_FILE = f"settings.json"
|
||||
# self._GLADE_FILE = f"Main_Window.glade"
|
||||
# self._CSS_FILE = f"stylesheet.css"
|
||||
# self._KEY_BINDINGS_FILE = f"key-bindings.json"
|
||||
# self._PID_FILE = f"{app_name.lower()}.pid"
|
||||
# self._WINDOW_ICON = f"{app_name.lower()}.png"
|
||||
# self._UI_WIDEGTS_PATH = f"ui_widgets"
|
||||
# self._CONTEXT_MENU = f"contexct_menu.json"
|
||||
# self._DEFAULT_ICONS = f"icons"
|
||||
|
||||
|
||||
# with zipfile.ZipFile("files.zip", mode="r", allowZip64=True) as zf:
|
||||
# with io.TextIOWrapper(zf.open("text1.txt"), encoding="utf-8") as f:
|
||||
@ -147,6 +159,7 @@ class Settings(StartCheckMixin, Singleton):
|
||||
def get_home_config_path(self) -> str: return self._HOME_CONFIG_PATH
|
||||
def get_window_icon(self) -> str: return self._WINDOW_ICON
|
||||
def get_home_path(self) -> str: return self._USER_HOME
|
||||
def make_transparent(self) -> int: return self._config["make_transparent"]
|
||||
|
||||
# Filter returns
|
||||
def get_office_filter(self) -> tuple: return tuple(self._settings["filters"]["office"])
|
||||
|
16
user_config/usr/share/app_name/contexct_menu.json
Normal file
16
user_config/usr/share/app_name/contexct_menu.json
Normal file
@ -0,0 +1,16 @@
|
||||
{
|
||||
"Open Actions": {
|
||||
"Open": ["STOCK_OPEN", "open"],
|
||||
"Open With": ["STOCK_OPEN", "open_with"],
|
||||
"Execute": ["STOCK_EXECUTE", "execute"],
|
||||
"Execute in Terminal": ["STOCK_EXECUTE", "execute_in_terminal"]
|
||||
},
|
||||
"File Actions": {
|
||||
"New": ["STOCK_ADD", "create"],
|
||||
"Rename": ["STOCK_EDIT", "rename"],
|
||||
"Cut": ["STOCK_CUT", "cut"],
|
||||
"Copy": ["STOCK_COPY", "copy"],
|
||||
"Paste": ["STOCK_PASTE", "paste"]
|
||||
},
|
||||
"Plugins": {}
|
||||
}
|
@ -15,7 +15,8 @@
|
||||
"text_app": "leafpad",
|
||||
"file_manager_app": "solarfm",
|
||||
"terminal_app": "terminator",
|
||||
"remux_folder_max_disk_usage": "8589934592"
|
||||
"remux_folder_max_disk_usage": "8589934592",
|
||||
"make_transparent": 0
|
||||
},
|
||||
"filters": {
|
||||
"meshs": [".blend", ".dae", ".fbx", ".gltf", ".obj", ".stl"],
|
||||
|
Loading…
Reference in New Issue
Block a user