gui/pkg/display/README.md
Virgil dc53b04d2a
Some checks failed
Security Scan / security (push) Failing after 30s
Test / test (push) Successful in 1m24s
refactor(ax): make window bounds and state updates more declarative
Co-Authored-By: Virgil <virgil@lethean.io>
2026-03-31 08:30:58 +00:00

29 lines
974 B
Markdown

# Display
`pkg/display` is the Core GUI display service. It owns window orchestration, layouts, menus, system tray state, dialogs, notifications, and the IPC bridge to the frontend.
## Working Locally
1. Run the backend tests:
```bash
go test ./pkg/display/...
```
2. Run the full workspace tests when you touch IPC contracts:
```bash
go test ./...
```
3. Build the Angular frontend:
```bash
cd ui
npm install
npm run build
```
## Declarative Windows
Windows are created from a `window.Window` spec instead of a fluent option chain.
Use `OpenWindow(window.Window{})` for the default app window, or `CreateWindow(window.Window{Name: "editor", Title: "Editor", URL: "/#/editor"})` when you need a named window and the returned `WindowInfo`.
Use `SetWindowBounds("editor", 100, 200, 1280, 720)` when you need to move and resize a window in one step.
The same spec shape is used by layout restore, tiling, snapping, and workflow presets.