8000 GitHub - klesh/JigsawWM: JigsawWM is a dynamic window manager for Windows10/11 just like the suckless dwm for the X
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

klesh/JigsawWM

Repository files navigation

JigsawWM

JigsawWM is a free and open-source productivity toolkit for Windows that brings advanced automation and tiling window management to your desktop.

It combines:

  • JMK Module β€” a programmable keyboard/mouse automation system inspired by QMK and an alternative to AutoHotkey.
  • Tiling Window Manager β€” automatically arranges your windows, freeing you from tedious manual window placement.
  • Daemon Framework β€” enables background services and daily workflow automation, all easily customizable.

πŸŽ₯ Demo

2023-01-01_18-56-36.mp4

πŸ“¦ Installation

Tested on:

  • Windows 11 (Build 22000)
  • Python 3.11.1

Also compatible with:

  • Windows 10
  • Python 3.8+

Install from PyPI:

pip install jigsawwm

Install from GitHub:

pip install git+https://github.com/klesh/JigsawWM.git

⚑ Quick Start

Step 1: Download and Customize

Download the example config file: example/full.pyw and adjust it to your needs.


πŸ”§ Step 1.1 - Configure General Keybindings (JMK)

JMK is a programmable input automation engine. Here are some useful examples:

1. Tap-Hold Modifier (e.g., CapsLock as Esc on tap, Ctrl on hold):

daemon.jmk.core.register_layers([
    {
        Vk.CAPITAL: JmkTapHold(tap=Vk.ESCAPE, hold=Vk.LCONTROL),
    },
])

πŸ’‘ Tip: Tap it and hold within quick_tap_term (default: 120ms) to send multiple Esc.

2. Access Keys with Layers (e.g., press T+Z to get F1):

daemon.jmk.core.register_layers([
    { Vk.T: JmkTapHold(tap=Vk.T, hold=3) },  # Layer switch
    {}, {}, {},
    { Vk.Z: JmkKey(Vk.F1) },  # Layer 3
])

3. Hotkeys (e.g., Win+Q to close window):

daemon.jmk.hotkeys.register_triggers([
    ("Win+q", "LAlt+F4"),
    ([Vk.WIN, Vk.N], minimize_active_window),
])

πŸͺŸ Step 1.2 - Configure the Window Manager

JigsawWM follows the suckless philosophy and mimics dwm, organizing windows in a strict order and layout for automatic tiling.

1. Window Navigation & Layouts

daemon.wm.hotkeys = [
    ([Vk.WIN, Vk.CTRL, Vk.J], daemon.wm.manager.next_window),
    ([Vk.WIN, Vk.CTRL, Vk.K], daemon.wm.manager.prev_window),
    ([Vk.WIN, Vk.SHIFT, Vk.J], daemon.wm.manager.swap_next),
    ([Vk.WIN, Vk.SHIFT, Vk.K], daemon.wm.manager.swap_prev),
    ("Win+Ctrl+/", daemon.wm.manager.set_master),
    ("Win+Ctrl+.", daemon.wm.manager.roll_next),
    ("Win+Ctrl+,", daemon.wm.manager.roll_prev),
    ([Vk.WIN, Vk.CONTROL, Vk.M], daemon.wm.manager.toggle_mono),
    ("Win+Shift+Space", daemon.wm.manager.toggle_tilable),
]

2. Workspaces (Per Monitor)

# Switch workspace
("Win+Ctrl+a", partial(daemon.wm.manager.switch_to_workspace, 0)),
("Win+Ctrl+s", partial(daemon.wm.manager.switch_to_workspace, 1)),

# Move window to workspace
("Win+Shift+a", partial(daemon.wm.manager.move_to_workspace, 0)),
("Win+Shift+s", partial(daemon.wm.manager.move_to_workspace, 1)),

3. Multi-Monitor Support

([Vk.WIN, Vk.U], daemon.wm.manager.prev_monitor),
([Vk.WIN, Vk.I], daemon.wm.manager.next_monitor),
([Vk.WIN, Vk.SHIFT, Vk.U], daemon.wm.manager.move_to_prev_monitor),
([Vk.WIN, Vk.SHIFT, Vk.I], daemon.wm.manager.move_to_next_monitor),

4. Window Rules

daemon.wm.manager.config = WmConfig(
    rules=[
        WmRule(exe="Flow.Launcher.exe", manageable=False),
        WmRule(exe="7zFM.exe", tilable=False),
    ]
)

βš™οΈ Step 1.3 - Manage Background Services

JigsawWM can manage external processes via tray menu:

daemon.register(
    ProcessService(
        name="syncthing",
        args=["syncthing.exe", "-no-browser", "-no-restart", "-no-upgrade"],
        log_path=os.path.join(os.getenv("LOCALAPPDATA"), "syncthing.log"),
    )
)

Tray


πŸ€– Step 1.4 - Automate Daily Routines

1. Open your daily folder in a browser once per day:

daemon.register(
    DailyWebsites(
        browser_name="thorium",
        fav_folder="daily",
        test_url="https://google.com",
        proxy_url="http://localhost:7890",
    )
)

2. Auto-launch apps on workdays:

daemon.register(
    WorkdayAutoStart(
        country_code="CN",
        apps=[
            r"C:\Users\Klesh\AppData\Local\Feishu\Feishu.exe",
            r"C:\Program Files\Betterbird\betterbird.exe",
            r"C:\Users\Klesh\AppData\Local\Programs\obsidian\Obsidian.exe",
        ],
    )
)

πŸš€ Step 2: Launch and Manage

Double-click your .pyw file. A tray icon will appear β€” right-click it to manage services.


πŸ”„ Step 3: Launch at Startup

  1. Press Win + R β†’ type shell:startup β†’ hit Enter
  2. Add a shortcut to your .pyw script in the folder

πŸ“š Documentation

πŸ‘‰ Read the Docs

About

JigsawWM is a dynamic window manager for Windows10/11 just like the suckless dwm for the X

Resources

License

Stars

Watchers

Forks

Packages

No packages published
0