Release Update

Updated MacroPad to support Tabs, fix system tray behavior, and break apart the monolith
This commit is contained in:
2025-06-01 14:02:29 -07:00
parent 896875ce90
commit 5727a9ee68
7 changed files with 60 additions and 83 deletions

10
main.py
View File

@@ -76,8 +76,10 @@ class MacroPadServer:
style.configure("TNotebook", background=THEME['bg_color'], borderwidth=0)
style.configure("TNotebook.Tab", background=THEME['tab_bg'], foreground=THEME['fg_color'],
padding=[12, 8], borderwidth=0)
style.map("TNotebook.Tab", background=[("selected", THEME['tab_selected'])],
foreground=[("selected", THEME['fg_color'])])
style.map("TNotebook.Tab",
background=[("selected", THEME['tab_selected'])],
foreground=[("selected", THEME['fg_color'])],
padding=[("selected", [12, 8])]) # Keep same padding when selected
def create_ui(self):
"""Create the main user interface"""
@@ -438,8 +440,8 @@ class MacroPadServer:
# Fall back to default font
font = ImageFont.load_default()
# Draw "M" in the center
text = "M"
# Draw "MP" in the center
text = "MP"
bbox = draw.textbbox((0, 0), text, font=font)
text_width = bbox[2] - bbox[0]
text_height = bbox[3] - bbox[1]