Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions bin/omarchy-menu
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,10 @@ show_screenrecord_menu() {
*"With desktop audio") omarchy-cmd-screenrecord --with-desktop-audio ;;
*"With desktop + microphone audio") omarchy-cmd-screenrecord --with-desktop-audio --with-microphone-audio ;;
*"With desktop + microphone audio + webcam")
local device=$(show_webcam_select_menu) || { back_to show_capture_menu; return; }
local device=$(show_webcam_select_menu) || {
back_to show_capture_menu
return
}
omarchy-cmd-screenrecord --with-desktop-audio --with-microphone-audio --with-webcam --webcam-device="$device"
;;
*) back_to show_capture_menu ;;
Expand Down Expand Up @@ -185,7 +188,7 @@ show_style_menu() {
case $(menu "Style" "󰸌 Theme\n Font\n Background\n Hyprland\n󱄄 Screensaver\n About") in
*Theme*) show_theme_menu ;;
*Font*) show_font_menu ;;
*Background*) omarchy-theme-bg-next ;;
*Background*) show_background_menu ;;
*Hyprland*) open_in_editor ~/.config/hypr/looknfeel.conf ;;
*Screensaver*) open_in_editor ~/.config/omarchy/branding/screensaver.txt ;;
*About*) open_in_editor ~/.config/omarchy/branding/about.txt ;;
Expand All @@ -197,6 +200,10 @@ show_theme_menu() {
omarchy-launch-walker -m menus:omarchythemes --width 800 --minheight 400
}

show_background_menu() {
omarchy-launch-walker -m menus:omarchyBackgroundSelector
}

show_font_menu() {
theme=$(menu "Font" "$(omarchy-font-list)" "--width 350" "$(omarchy-font-current)")
if [[ "$theme" == "CNCLD" || -z "$theme" ]]; then
Expand Down Expand Up @@ -588,6 +595,7 @@ go_to_menu() {
*learn*) show_learn_menu ;;
*trigger*) show_trigger_menu ;;
*share*) show_share_menu ;;
*background*) show_background_menu ;;
*capture*) show_capture_menu ;;
*style*) show_style_menu ;;
*theme*) show_theme_menu ;;
Expand Down
3 changes: 2 additions & 1 deletion bin/omarchy-theme-set
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ rm -rf "$CURRENT_THEME_PATH"
mv "$NEXT_THEME_PATH" "$CURRENT_THEME_PATH"

# Store theme name for reference
echo "$THEME_NAME" > "$HOME/.config/omarchy/current/theme.name"
echo "$THEME_NAME" >"$HOME/.config/omarchy/current/theme.name"

# Change background with theme
omarchy-theme-bg-next
Expand All @@ -51,6 +51,7 @@ omarchy-restart-hyprctl
omarchy-restart-btop
omarchy-restart-opencode
omarchy-restart-mako
omarchy-restart-walker

# Change app-specific themes
omarchy-theme-set-gnome
Expand Down
40 changes: 40 additions & 0 deletions default/elephant/omarchy_background_selector.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
Name = "omarchyBackgroundSelector"
NamePretty = "Omarchy Background Selector"
Cache = true
HideFromProviderlist = true
SearchName = true

function GetEntries()
local entries = {}
local wallpaper_dir = os.getenv("HOME") .. "/.config/omarchy/current/theme/backgrounds"
local handle = io.popen(
"find '"
.. wallpaper_dir
..
"' -maxdepth 1 -type f -name '*.jpg' -o -name '*.jpeg' -o -name '*.png' -o -name '*.gif' -o -name '*.bmp' -o -name '*.webp' 2>/dev/null"
)
if handle then
for background in handle:lines() do
local filename = background:match("([^/]+)$")
if filename then
table.insert(entries, {
Text = filename,
Value = background,
Actions = {
activate = "ln -sf '"
.. background
.. "' "
.. os.getenv("HOME")
.. "/.config/themes/current/background && killall swaybg 2>/dev/null ; swaybg -o '*' -i '"
.. background
.. "' -m fill &",
},
Preview = background,
PreviewType = "file",
})
end
end
handle:close()
end
return entries
end
1 change: 1 addition & 0 deletions install/config/walker-elephant.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,4 @@ EOF
# Link the visual theme menu config
mkdir -p ~/.config/elephant/menus
ln -snf $OMARCHY_PATH/default/elephant/omarchy_themes.lua ~/.config/elephant/menus/omarchy_themes.lua
ln -snf $OMARCHY_PATH/default/elephant/omarchy_background_selector.lua ~/.config/elephant/menus/omarchy_background_selector.lua
4 changes: 4 additions & 0 deletions migrations/1770380577.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#link the visual background selector menu config

mkdir -p ~/.config/elephant/menus
ln -snf $OMARCHY_PATH/default/elephant/omarchy_background_selector.lua ~/.config/elephant/menus/omarchy_background_selector.lua