Browse wallhaven and generate themes via aether from the theme switcher#5878
Open
bjarneo wants to merge 2 commits into
Open
Browse wallhaven and generate themes via aether from the theme switcher#5878bjarneo wants to merge 2 commits into
bjarneo wants to merge 2 commits into
Conversation
The "+" tile at the end of the carousel loads wallhaven's monthly toplist inline. Scrolling near the end auto-fetches the next batch. Picking an image downloads it and runs aether --generate to build and apply the theme.
Contributor
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
This PR extends the Quickshell image selector to support an “action” tile (a synthetic “+” entry) that can run a command to append more results (e.g., Wallhaven), and updates the theme switcher flow to handle selecting either local previews or remote URLs.
Changes:
- Add an action tile/keybinding to the QML carousel, including auto-fetch near the end and support for appending rows over IPC.
- Implement Wallhaven fetch + append via a new helper script, and update the theme switcher to download/apply URLs.
- Extend
omarchy-menu-imagesIPC payload to include action metadata.
Reviewed changes
Copilot reviewed 1 out of 4 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
| default/quickshell/select-by-image.qml | Adds action tile/key handling, append IPC op, URL support, palette rendering, and auto-fetch logic. |
| bin/omarchy-theme-switcher | Uses action tile to fetch Wallhaven results; handles URL selections by downloading + applying via aether. |
| bin/omarchy-theme-from-wallhaven | New script to fetch Wallhaven pages and append results to the running selector via socket IPC. |
| bin/omarchy-menu-images | Adds CLI flags and IPC fields for action key/label/command to drive the new QML behavior. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+340
to
+346
| function triggerAction() { | ||
| if (!hasAction || actionProc.running) return | ||
|
|
||
| autoLoadActive = true | ||
| actionProc.command = ["bash", "-lc", actionCommand] | ||
| actionProc.running = true | ||
| } |
| } else if (root.hasActionKey && event.text && event.text.toLowerCase() === root.actionKey.toLowerCase() && (event.modifiers === Qt.NoModifier || event.modifiers === Qt.ShiftModifier)) { | ||
| // Action key takes precedence over filter typing so the bound key | ||
| // can't be "captured" by an active filter session. Pressing it | ||
| // closes the selector and runs actionCommand in the background. |
| maybeAutoFetch() | ||
| } | ||
|
|
||
| function openSelector(nextImageDirs, nextImageRows, nextSelectedImage, nextSelectionFile, nextDoneFile, nextColorsFile, nextColorsRaw, nextShowLabels, nextFilterable, nextActionKey, nextActionLabel, nextActionCommand, nextNearbyWindow) { |
Comment on lines
+617
to
+634
| // High-quality overlay. Loads for the 3 cards on either side of | ||
| // the active one so the full wallpaper is already decoded by | ||
| // the time the user lands on it. Visibility is gated to the | ||
| // active card only - the preloaded neighbours sit in Qt's | ||
| // pixmap cache invisible until they're scrolled to. | ||
| // | ||
| // For local-file callers filePath == thumbnailPath so source | ||
| // stays empty and this overlay never activates. | ||
| Image { | ||
| id: imageFull | ||
| anchors.fill: parent | ||
| source: (item.nearby && Math.abs(item.relativeIndex) <= 3 | ||
| && item.filePath && item.filePath !== item.thumbnailPath) | ||
| ? root.fileUrl(item.filePath) : "" | ||
| fillMode: Image.PreserveAspectCrop | ||
| asynchronous: true | ||
| cache: true | ||
| smooth: true |
- Exec actionCommand directly instead of via bash -lc - Take an options object for openSelector - Fix stale comments on triggerAction and the imageFull overlay
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.
The "+" tile at the end of the carousel loads wallhaven's monthly toplist inline. Scrolling near the end auto-fetches the next batch. Picking an image downloads it and runs aether --generate to build and apply the theme.
omarchy_wp_extract_wallhaven_aether_small.mp4