Linux: Chromium CDP backend (zero-compile alternative to WebKitGTK)#8
Merged
HazAT merged 1 commit intoHazAT:mainfrom Mar 20, 2026
Merged
Linux: Chromium CDP backend (zero-compile alternative to WebKitGTK)#8HazAT merged 1 commit intoHazAT:mainfrom
HazAT merged 1 commit intoHazAT:mainfrom
Conversation
59aeb42 to
51e5b27
Compare
New backend that uses system Chromium/Chrome via CDP pipe as an alternative to the Rust/GTK4/WebKitGTK native binary. Zero compilation, zero native dependencies beyond a system browser. - src/chromium-backend.mjs: standalone backend (~970 lines) Speaks Glimpse JSON Lines on stdin/stdout, translates to CDP over pipe (FDs 3/4) to a Chrome process launched with --app mode. - Full feature parity with native backends: Window modes (frameless, floating, transparent, click-through) via xprop/xdotool/XFixes. Follow cursor on X11 via xdotool polling (not just Hyprland). Status item via GTK StatusIcon Python helper. Open links via xdg-open. Spring physics, cursor anchors, hidden/prewarm, auto-close. - src/glimpse.mjs: auto-fallback when native binary not built GLIMPSE_BACKEND=chromium to force, GLIMPSE_BACKEND=native to require native. statusItem() now works on linux-chromium too. - src/follow-cursor-support.mjs: reports X11 as supported when Chromium backend is active. - test/test-chromium.mjs: 15 test suites, 36 assertions covering every feature. - glimpse-chromium.md: design doc with architecture, protocol mapping, and implementation notes.
51e5b27 to
d78ff7c
Compare
Owner
|
thx |
HazAT
added a commit
that referenced
this pull request
Mar 20, 2026
Add changelog entry for the two community contributions in this release: - PR #8 (@hjanuschka): Chromium CDP backend for Linux — a zero-compile alternative to WebKitGTK that auto-falls back to system Chromium via remote-debugging-pipe. Adds follow-cursor on X11, system tray support, and external link opening on Linux. - PR #7 (@Whamp): Linux CLI fixes for negative number arg parsing and platform-gated options that caused startup failures. Update README to document the Chromium CDP backend: platform table, build instructions (Option A native / Option B zero-compile), expanded platform notes matrix splitting Linux native vs Chromium columns, GLIMPSE_BACKEND env var, and architecture listing.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
New Linux backend that uses system Chromium via CDP pipe instead of WebKitGTK. No Rust, no GTK dev packages, no compile step -- just needs a browser installed.
When the native binary isn't built, Glimpse auto-falls back to spawning
chromium --app --remote-debugging-pipeand talking CDP over FDs 3/4. A ~1k line Node script (src/chromium-backend.mjs) translates between our JSON Lines protocol and CDP. From the caller side nothing changes.This also unlocks stuff the native Linux backend can't do:
Window modes work via X11 tooling after the Chrome window appears:
_MOTIF_WM_HINTSremoval via xprop_NET_WM_STATE_ABOVEvia xpropEmulation.setDefaultBackgroundColorOverride