lol
This commit is contained in:
1 parent
2095c1f071
commit
1b7ec29d26
52 files changed
+18934
No files matched your search
@@ -0,0 +1,43 @@
|
||||
from __init__ import *
|
||||
|
||||
|
||||
def apply_style(app: Application):
|
||||
logger.info("[Main] CSS applied")
|
||||
app.set_stylesheet_from_file(get_relative_path("style/main.css"))
|
||||
app.set_stylesheet_from_file(f"/home/{os.getlogin()}/.cache/material/colors.css")
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
sc = ScreenRecorder()
|
||||
brightness = Brightness()
|
||||
|
||||
logger.disable("fabric.hyprland.widgets")
|
||||
bar = Bar()
|
||||
|
||||
launcher = Launcher()
|
||||
launcher.hide()
|
||||
|
||||
setting = Settings()
|
||||
setting.hide()
|
||||
|
||||
app = Application(
|
||||
"fabric-bar",
|
||||
bar,
|
||||
launcher,
|
||||
setting,
|
||||
)
|
||||
|
||||
# Monitor main.css file for changes
|
||||
main_css_file = monitor_file(get_relative_path("style/main.css"))
|
||||
main_css_file.connect("changed", lambda *args: apply_style(app))
|
||||
|
||||
# Monitor colors.css file for changes
|
||||
color_css_file = monitor_file(f"/home/{os.getlogin()}/.cache/material/colors.css")
|
||||
color_css_file.connect("changed", lambda *args: apply_style(app))
|
||||
|
||||
apply_style(app)
|
||||
|
||||
def quit_fabric():
|
||||
app.quit()
|
||||
|
||||
app.run()
|
||||
Reference in new issue
Block a user