Hypr Canvas banner
aaronsb aaronsb

Hypr Canvas

Development community

Description

Infinite canvas plugin for Hyprland — zoom and pan your desktop like a map

Installation

This entry records only its repository, not the path inside it, so there is no exact command to give. Open the source below and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

README

hypr-canvas

An infinite canvas plugin for [Hyprland](https://hyprland.org). Zoom out to see all your windows at once, pan around a vast virtual desktop, and zoom back in to work — like Google Maps for your desktop.

**⚠️ Super alpha.** This plugin hooks deep into Hyprland's internals. It may set your computer on fire, cause a divide by zero when maximizing an application, and form a black hole ending our universe. You have been warned.

Demo

**Super+Scroll** to zoom in/out. **Super+Left-Drag** on empty space to pan.

Works with both native Wayland apps and XWayland apps (Chrome, Discord, Electron).

Install

Requires Hyprland and its development headers. The plugin builds against whatever version you have installed — the ABI version is pulled from your headers at compile time.

# build
make

# load into your running Hyprland session
make install

# or if you're iterating (bypasses dlopen cache)
make reload

To load it automatically, add to your `hyprland.conf`:

plugin = /path/to/hypr-canvas.so

To unload:

make unload

How It Works

The plugin hooks 12 functions inside Hyprland to intercept rendering, input, coordinate mapping, and popup positioning. No source patches needed — it's a pure plugin using `createFunctionHook`.

Coordinate Spaces

Physical space: monitor pixels (0,0)-(7680,2160)
                hardware cursor always lives here
                                    │
                          position() hook
                          offset + physical / zoom
                                    │
                                    ▼
Canvas space:   infinite plane where windows exist
                at their normal Hyprland positions

**Rendering** transforms canvas → physical: `screenPos = (canvasPos - offset) * zoom`

**Input** transforms physical → canvas: `canvasPos = offset + screenPos / zoom`

Hook Summary

Hook What it does
onMouseWheel Super+scroll → c