Commit Graph
19 Commits
Author SHA1 Message Date
DaxandHex issue pipeline ba8a92da91 Fix #465: recording HUD on GNOME Wayland (#466)
Automated fix from the Hex issue pipeline (run 465-2026-10-30t12-16-38-773z).

Fixes #465

Co-authored-by: Hex issue pipeline <noreply@anoma.ly>
2026-10-30 08:19:46 -04:00
DaxandHex issue pipeline cfd490b9c7 Fix #444: Linux Wayland paste (Terminal paste) on Hyprland (#454)
Automated fix from the Hex issue pipeline (run 444-2026-10-30t09-35-28-516z).

Fixes #444

Co-authored-by: Hex issue pipeline <noreply@anoma.ly>
2026-10-30 05:42:27 -04:00
Kit Langton 3343015778 chore: remove Voice Action (t733) (#423) 2026-10-29 15:56:51 -07:00
Dax 83e0825909 fix(linux): restore the previous clipboard after a paste (#415)
Linux paste now snapshots every format of the clipboard before writing the
transcript and restores it 500 ms after the paste shortcut, as macOS does,
unless a later paste, copy, or another client replaced it. Wayland reads and
serves through wlr-data-control; X11 through Hex's own selection owner with
INCR. Empty clipboards stay empty; clipboards over 32 MiB are left, with a log
line. Thanks to @shashankx86 for the report.

Fixes #391
2026-10-29 17:22:56 -04:00
Dax 8b3af3aa29 Annotate: hold to draw on Linux, no send-to list shortcut, inline sends, Paste-first capsule (#406)
- Linux draws while Ctrl+Alt+D is held (portal Activated/Deactivated), as Shift on the Mac; moving draws, a click pins, right-click or Ctrl+Z undoes. `hex annotate draw` stays a toggle.
- The send-to list shortcut (capture.list_hotkey, ⌥⇧L / Ctrl+Alt+Shift+V) is gone; Send to… is a capsule click beside Paste and Inspect.
- Sends attach the contact sheet and up to 8 keyframes inline as data: image parts, with no local path in the prompt, so remote OpenCode servers get everything.
- Dictation and Voice Action start nothing while Annotate records (macOS and Linux).
- Linux Paste pastes the contact sheet, then the summary, as the Mac does; the Linux capsule doesn't open suggestions by itself.
- Settings › Annotate gains How it works.
2026-10-29 16:41:49 -04:00
Dax 3089bafbd5 fix(linux): wait for shortcut modifiers before the Wayland paste (#353) (#354) 2026-10-29 07:20:16 -04:00
Dax de8ace2a9f fix(linux): paste through the RemoteDesktop portal without virtual keyboards (#347)
Wayland paste keeps wtype where the compositor offers
zwp_virtual_keyboard_manager_v1 and otherwise sends Ctrl+V through the
desktop's RemoteDesktop portal: one keyboard-only session, approved once
with a persisted restore token. With neither, the transcript stays copied
and the failure names the missing portal.

A loose binary writes its own managed hex.desktop so the portal can
identify it. Settings opens the GlobalShortcuts dialog (ConfigureShortcuts)
where the portal supports it, follows ShortcutsChanged, and treats an empty
trigger as refused.

Fixes #346
2026-10-29 02:45:17 -04:00
Dax 2962074bfa Captures on Linux (portal, PipeWire, VA-API); capture compiled into macOS and Linux builds (#320)
* Captures on Linux: portal, PipeWire and VA-API behind the engine's platform seam; capture compiled into macOS and Linux builds

The capture engine's OS adapter gains capture/linux.rs: the screen-cast
portal (zbus) picks the screen (remembered with its restore token) or a
window, libpipewire and libva are loaded at run time, frames are imported
as DMA-BUFs and scaled and H.264-encoded on the GPU, and ffmpeg muxes and
reads movies back. Software x264 is the fallback.

capture_host, the capsule, the pane, routing and the CLI are shared; the
Linux listener feeds a ListenerTimeline, its portal or X11 grabs bind the
capture shortcut, and the summary goes through Hex's Linux clipboard.
The capture feature flag is gone: macOS and Linux always compile the
experiment, off by default.

* Docs: captures on Linux, the experiment in every macOS and Linux build; token path from Hex

* Capture portal: register Hex's app id so the desktop keeps its screen choice

* Fix macOS test build after the capture seam

* Linux: size X11 shortcut state for the capture shortcut; keep macOS-layout capsule tests on macOS

* Windows: the capture word timestamps field is Linux's
2026-10-28 20:58:27 -04:00
Dax Raad 0eeeb2bde3 fix(linux, windows): apply saved settings to the running listener in place
Changing a setting stopped the listener and started it again, so the
Status card flashed Disabling/Enabling. The host now hands the running
listener its saved settings: paste, indicator, audio behavior, sounds,
and modes apply at once; shortcut changes register again, a microphone
change reopens the stream, and a model or hint change loads beside the
current model and swaps it in once nothing is pending (ModelSwap).
Recording a shortcut suspends only global matching. Windows drops its
'Applying settings' restart the same way.
2026-10-22 19:50:34 -04:00
Dax Raad 5a79b47f96 refactor(linux): simplify single-process host, shortcuts, portals, HUD, and updater 2026-10-22 17:46:39 -04:00
Dax Raad 1577c19b52 feat(linux): portal shortcuts and hex commands replace raw Wayland input
Wayland shortcuts no longer read /dev/input. One state machine in
linux_input now serves every source:

- X11: the existing key grabs, with auto-repeat filtering split out and
  tested, and the inline gesture flags replaced by the shared rules.
- Wayland with the GlobalShortcuts portal: Register("hex"), one session for
  dictation, Paste Last, and Voice Action, and a second session that binds
  Escape (also with the held shortcut's modifiers) only while recording.
  Activated/Deactivated are press/release; refused shortcuts and the
  trigger the desktop actually granted show in Settings; a closed session
  cancels and stops the listener with an error.
- Everywhere: `hex dictation start|stop|toggle|cancel`,
  `hex voice-action start|stop|toggle`, and `hex paste-last` talk to the
  running service over its socket for desktops without the portal. They
  are idempotent, never start the service, and fail clearly when it is
  missing or not listening.

Settings records shortcuts from its own key events on Wayland too, lists
the granted triggers, or, without the portal, hides the shortcut rows and
lists the commands. Wayland paste no longer waits for held modifiers:
wtype's virtual keyboard sends its own, and the Wayland paste smoke now
pastes while another keyboard holds Ctrl and Alt.

Removes linux_wayland_input.rs, the evdev and udev crates, libudev-dev in
CI, and every input-group requirement from the docs. Also gates
AppWindowPreview::pane to macOS, whose only callers broke the Linux
Clippy build.
2026-10-22 01:13:07 -04:00
Luke Parker e5c3e3d4ca feat(linux): Voice Action on Linux (#151)
* feat(linux): Voice Action on Linux

Holding the Voice Action shortcut records an instruction on X11 and
Wayland. The listener pairs it with the primary selection, asks OpenCode
with the saved Voice Action settings, and pastes the reply. Settings
records the shortcut through the service, like the others.

* fix(linux): share the settings-driven Voice Action call with Linux
2026-10-19 15:04:38 +10:00
Kit Langton f249917ef6 refactor: simplify codebase and align desktop UI with OpenCode 2026-10-06 23:29:09 -07:00
Kit Langton 04a42dae3d refactor: consolidate settings commits, transcription padding, and SDK framing
Settings controls commit a full candidate before changing the saved UI choice,
so a failed write keeps shortcut capture open and preserves pending debounced
edits. The macOS Transcriber owns backend input padding for ordinary,
voice-protocol, and segmented transcription. Moonshine stream cleanup and the
Linux client share one owner-side path. The command SDK shares capture
normalization between constructors and host registration, and the public SDK
decodes model progress and dictation levels with one bounded SSE framer. The
signing scripts share one identity helper, and historical release evidence
moves out of the feature map.
2026-09-22 17:08:43 -07:00
Dax Raad 742fc0e86d fix(linux): remove Wayland dictation paste delay 2026-09-12 16:45:14 -04:00
Kit Langton be9c368a00 feat(linux): add wlroots Wayland support and Nix packaging (#36)
* feat(linux): add wlroots Wayland support and Nix packaging

* fix(linux): preserve pending status and verify native coexistence

* test(linux): verify real dictation through a virtual microphone

* test(linux): bound smoke cleanup and check microphone release

* test(linux): isolate installer XDG paths from the host

* test(linux): exercise the desktop dictation lifecycle

* refactor(linux): simplify worker completion and input snapshots
2026-08-28 12:05:21 -04:00
Dax Raad 11d30262f5 feat: add Linux X11 dictation preview 2026-07-18 20:19:05 -04:00
Dax Raad 04ea332053 Revert "feat: add Linux X11 dictation preview"
This reverts commit c65421be82.
2026-07-18 20:18:40 -04:00
Dax Raad c65421be82 feat: add Linux X11 dictation preview 2026-07-18 20:07:57 -04:00