Fix power profile menu, screen sharing, screenshot HDR, and NVIDIA stability#5415
Conversation
There was a problem hiding this comment.
Pull request overview
This PR aims to address four user-reported regressions/issues in Omarchy around Walker menu sizing, Hyprland screen-sharing indicator interaction, HDR/Hyprpicker screenshot behavior, and NVIDIA/Chromium stability.
Changes:
- Update Walker launcher to only apply default sizing args when the caller didn’t provide
--width/--maxheight/--minheight. - Add new Hyprland screen-sharing rule config and source it from the default app rules.
- Add migrations and an NVIDIA Chromium flags installer intended to improve NVIDIA stability, plus a wayfreeze-related migration for screenshots.
Reviewed changes
Copilot reviewed 6 out of 8 changed files in this pull request and generated 8 comments.
Show a summary per file
| File | Description |
|---|---|
bin/omarchy-launch-walker |
Adjusts argument passthrough so defaults don’t override caller-provided sizing. |
bin/omarchy-cmd-screenshot |
Introduces a wayfreeze-based capture path intended to improve results on HDR/NVIDIA. |
default/hypr/apps.conf |
Sources a new screen-sharing-specific Hyprland rules file. |
default/hypr/apps/screen-sharing.conf |
Adds Hyprland rules intended to make browser sharing indicators clickable. |
install/config/nvidia-chromium-flags.sh |
Adds a helper intended to provide NVIDIA-optimized Chromium/Electron flags. |
migrations/1777007316.sh |
Migration intended to apply the screen-sharing interaction fix. |
migrations/1777007317.sh |
Migration intended to apply NVIDIA Wayland stability environment overrides. |
migrations/1777007318.sh |
Migration intended to optionally re-install wayfreeze for screenshot compatibility. |
[!TIP]
If you aren't ready for review, convert to a draft PR.
Click "Convert to draft" or rungh pr ready --undo.
Click "Ready for review" or rungh pr readyto reengage.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| # Add NVIDIA-specific environment variables | ||
| NVIDIA_ENV_FILE="$HOME/.config/hypr/env-nvidia.conf" | ||
|
|
||
| if [[ ! -f $NVIDIA_ENV_FILE ]]; then | ||
| cat > "$NVIDIA_ENV_FILE" << 'CONFEOF' |
There was a problem hiding this comment.
This writes NVIDIA env overrides to ~/.config/hypr/env-nvidia.conf, but the shipped Hyprland config doesn’t source that file (it sources specific known files like the default envs.conf). Unless you also add a source = for this file (or append to a sourced env file), this migration won’t have any effect.
| # Add NVIDIA-specific environment variables | |
| NVIDIA_ENV_FILE="$HOME/.config/hypr/env-nvidia.conf" | |
| if [[ ! -f $NVIDIA_ENV_FILE ]]; then | |
| cat > "$NVIDIA_ENV_FILE" << 'CONFEOF' | |
| # Add NVIDIA-specific environment variables to a sourced Hyprland env file | |
| NVIDIA_ENV_FILE="$HOME/.config/hypr/envs.conf" | |
| mkdir -p "$(dirname "$NVIDIA_ENV_FILE")" | |
| if ! grep -Fq "# NVIDIA-specific environment variables for better Wayland compatibility" "$NVIDIA_ENV_FILE" 2>/dev/null; then | |
| cat >> "$NVIDIA_ENV_FILE" << 'CONFEOF' |
|
|
||
| # Use X11 backend instead of Wayland for Chromium on NVIDIA | ||
| # Wayland + NVIDIA + Chromium can cause lockups | ||
| export CHROMIUM_FLAGS="--ozone-platform=x11 --enable-features=VaapiVideoDecoder,VaapiVideoEncoder --disable-features=Vulkan, VulkanFromANGLE, DefaultANGLEVulkan" |
There was a problem hiding this comment.
CHROMIUM_FLAGS includes spaces after commas in --disable-features=Vulkan, VulkanFromANGLE, .... If this string is later expanded into args, those spaces can split the value and break Chromium’s flag parsing. Use a comma-separated list without spaces (or ensure the flags are passed as an array).
| export CHROMIUM_FLAGS="--ozone-platform=x11 --enable-features=VaapiVideoDecoder,VaapiVideoEncoder --disable-features=Vulkan, VulkanFromANGLE, DefaultANGLEVulkan" | |
| export CHROMIUM_FLAGS="--ozone-platform=x11 --enable-features=VaapiVideoDecoder,VaapiVideoEncoder --disable-features=Vulkan,VulkanFromANGLE,DefaultANGLEVulkan" |
| windowrule = opacity 1.0 1.0, class:^(chrome-shill-webui|chrome-webui-media-router|chrome-extension),title:.*(screen|sharing|tab|cast).* | ||
| windowrule = nofocus, class:^(chrome-shill-webui|chrome-webui-media-router),title:.*indicator.* | ||
|
|
||
| # Ensure notification popups from browsers receive input | ||
| windowrule = float, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | ||
| windowrule = noborder, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | ||
| windowrule = noblur, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | ||
|
|
||
| # Force the WebRTC indicator to be focusable and receive mouse events | ||
| layerrule = ignore_zero_containers on, class:^(chrome-shill-webui|chrome-webui-media-router)$ | ||
| layerrule = no_anim on, class:^(chrome-shill-webui|chrome-webui-media-router)$ |
There was a problem hiding this comment.
Hyprland config in this repo uses the 0.53+ match: syntax (e.g. match:class, match:title) and rules like no_focus on. These windowrule lines use class:/title: and nofocus, so they are likely ignored and won’t affect the WebRTC indicator windows.
| windowrule = opacity 1.0 1.0, class:^(chrome-shill-webui|chrome-webui-media-router|chrome-extension),title:.*(screen|sharing|tab|cast).* | |
| windowrule = nofocus, class:^(chrome-shill-webui|chrome-webui-media-router),title:.*indicator.* | |
| # Ensure notification popups from browsers receive input | |
| windowrule = float, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | |
| windowrule = noborder, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | |
| windowrule = noblur, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | |
| # Force the WebRTC indicator to be focusable and receive mouse events | |
| layerrule = ignore_zero_containers on, class:^(chrome-shill-webui|chrome-webui-media-router)$ | |
| layerrule = no_anim on, class:^(chrome-shill-webui|chrome-webui-media-router)$ | |
| windowrule = opacity 1.0 1.0, match:class:^(chrome-shill-webui|chrome-webui-media-router|chrome-extension), match:title:.*(screen|sharing|tab|cast).* | |
| windowrule = no_focus on, match:class:^(chrome-shill-webui|chrome-webui-media-router), match:title:.*indicator.* | |
| # Ensure notification popups from browsers receive input | |
| windowrule = float, match:class:^(chrome|chromium|brave|microsoft-edge), match:title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | |
| windowrule = noborder, match:class:^(chrome|chromium|brave|microsoft-edge), match:title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | |
| windowrule = noblur, match:class:^(chrome|chromium|brave|microsoft-edge), match:title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | |
| # Force the WebRTC indicator to be focusable and receive mouse events | |
| layerrule = ignore_zero_containers on, match:class:^(chrome-shill-webui|chrome-webui-media-router)$ | |
| layerrule = no_anim on, match:class:^(chrome-shill-webui|chrome-webui-media-router)$ |
| windowrule = float, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | ||
| windowrule = noborder, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | ||
| windowrule = noblur, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) |
There was a problem hiding this comment.
These rules also use windowrule = float / noborder / noblur without the ... on pattern and without match: selectors seen elsewhere in the repo. If Hyprland ignores them, the intended clickability fix won’t apply.
| windowrule = float, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | |
| windowrule = noborder, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | |
| windowrule = noblur, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | |
| windowrule = float on match:class:^(chrome|chromium|brave|microsoft-edge)$,title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide).* | |
| windowrule = noborder on match:class:^(chrome|chromium|brave|microsoft-edge)$,title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide).* | |
| windowrule = noblur on match:class:^(chrome|chromium|brave|microsoft-edge)$,title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide).* |
| mkdir -p "$CHROMIUM_FLAGS_DIR" | ||
|
|
||
| # Create a helper script that sets NVIDIA-optimized flags | ||
| cat > "$HOME/.config/chromium-flags/set-flags" << 'EOF' | ||
| #!/bin/bash | ||
| # NVIDIA-optimized Chromium flags for Wayland | ||
| # Prevents system lockups on media-heavy sites | ||
|
|
||
| # Use X11 backend instead of Wayland for Chromium on NVIDIA | ||
| # Wayland + NVIDIA + Chromium can cause lockups | ||
| export CHROMIUM_FLAGS="--ozone-platform=x11 --enable-features=VaapiVideoDecoder,VaapiVideoEncoder --disable-features=Vulkan, VulkanFromANGLE, DefaultANGLEVulkan" | ||
|
|
||
| # Apply to Electron apps too | ||
| export ELECTRON_OZONE_PLATFORM_HINT=x11 | ||
| EOF | ||
|
|
||
| chmod +x "$HOME/.config/chromium-flags/set-flags" | ||
|
|
There was a problem hiding this comment.
Omarchy’s Chromium flag management appears to use ~/.config/chromium-flags.conf (see bin/omarchy-refresh-chromium). This installer writes a separate ~/.config/chromium-flags/set-flags script, but nothing in the repo invokes or sources it, so the NVIDIA flags likely never apply.
| mkdir -p "$CHROMIUM_FLAGS_DIR" | |
| # Create a helper script that sets NVIDIA-optimized flags | |
| cat > "$HOME/.config/chromium-flags/set-flags" << 'EOF' | |
| #!/bin/bash | |
| # NVIDIA-optimized Chromium flags for Wayland | |
| # Prevents system lockups on media-heavy sites | |
| # Use X11 backend instead of Wayland for Chromium on NVIDIA | |
| # Wayland + NVIDIA + Chromium can cause lockups | |
| export CHROMIUM_FLAGS="--ozone-platform=x11 --enable-features=VaapiVideoDecoder,VaapiVideoEncoder --disable-features=Vulkan, VulkanFromANGLE, DefaultANGLEVulkan" | |
| # Apply to Electron apps too | |
| export ELECTRON_OZONE_PLATFORM_HINT=x11 | |
| EOF | |
| chmod +x "$HOME/.config/chromium-flags/set-flags" | |
| CHROMIUM_FLAGS_FILE="$HOME/.config/chromium-flags.conf" | |
| mkdir -p "$CHROMIUM_FLAGS_DIR" | |
| # Write NVIDIA-optimized Chromium flags to the config file Omarchy reads | |
| cat > "$CHROMIUM_FLAGS_FILE" << 'EOF' | |
| # NVIDIA-optimized Chromium flags for Wayland systems with NVIDIA GPUs | |
| --ozone-platform=x11 | |
| --enable-features=VaapiVideoDecoder,VaapiVideoEncoder | |
| --disable-features=Vulkan,VulkanFromANGLE,DefaultANGLEVulkan | |
| EOF |
| source = ~/.local/share/omarchy/default/hypr/apps/terminals.conf | ||
| source = ~/.local/share/omarchy/default/hypr/apps/walker.conf | ||
| source = ~/.local/share/omarchy/default/hypr/apps/webcam-overlay.conf | ||
| source = ~/.local/share/omarchy/default/hypr/apps/screen-sharing.conf |
There was a problem hiding this comment.
default/hypr/apps/browser.conf already has a rule that moves screen-sharing bars matching .*is sharing.* to a special workspace (hiding them). If the goal is to make the bar clickable (so the Hide button works), that existing rule may still apply and effectively bypass this new config; consider updating/removing the older rule to avoid conflicting behavior.
| source = ~/.local/share/omarchy/default/hypr/apps/screen-sharing.conf | |
| # screen-sharing.conf is intentionally not sourced here because browser.conf | |
| # already contains screen-sharing window rules; loading both creates | |
| # conflicting behavior until the older browser rule is updated/removed. |
| layerrule = ignore_zero_containers on, class:^(chrome-shill-webui|chrome-webui-media-router)$ | ||
| layerrule = no_anim on, class:^(chrome-shill-webui|chrome-webui-media-router)$ |
There was a problem hiding this comment.
layerrule matching in this repo uses match:namespace (see default/hypr/apps/hyprshot.conf). Using class: here is likely invalid for layer rules, so these directives probably won't have any effect.
| layerrule = ignore_zero_containers on, class:^(chrome-shill-webui|chrome-webui-media-router)$ | |
| layerrule = no_anim on, class:^(chrome-shill-webui|chrome-webui-media-router)$ | |
| layerrule = ignore_zero_containers on, match:namespace:^(chrome-shill-webui|chrome-webui-media-router)$ | |
| layerrule = no_anim on, match:namespace:^(chrome-shill-webui|chrome-webui-media-router)$ |
| windowrule = float, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | ||
| windowrule = noborder, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | ||
| windowrule = noblur, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) |
There was a problem hiding this comment.
The windowrule syntax emitted by this migration (class:/title: qualifiers and windowrule = float without match: selectors) doesn’t match the Hyprland 0.53+ syntax used in the shipped configs. This likely results in the rules being ignored, so the migration wouldn’t fix #5373.
| windowrule = float, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | |
| windowrule = noborder, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | |
| windowrule = noblur, class:^(chrome|chromium|brave|microsoft-edge),title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide) | |
| windowrule = float, match:(class:^(chrome|chromium|brave|microsoft-edge)$,title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide)) | |
| windowrule = noborder, match:(class:^(chrome|chromium|brave|microsoft-edge)$,title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide)) | |
| windowrule = noblur, match:(class:^(chrome|chromium|brave|microsoft-edge)$,title:.*(screen sharing|Sharing|is sharing|Stop sharing|Hide)) |
…ability
This commit addresses 4 bugs reported by users:
1. Power profile GUI not switching when clicked (#power-profile)
- Fix omarchy-launch-walker to properly pass through --width,
--maxheight, --minheight arguments to walker
- Prevents walker defaults from overriding menu-specific arguments
- Users can now properly select power profiles from the GUI menu
2. Screen sharing notification bar 'Hide' button not responding
- Add window rules for Chromium/Chrome WebRTC indicator windows
- Ensure notification popups receive input events properly
- Fixes: basecamp#5373
3. Screenshot regression with hyprpicker on HDR displays
- Add wayfreeze fallback for HDR displays
- wayfreeze provides proper color handling for HDR screenshots
- Add migration to reinstall wayfreeze for HDR users
- Fixes: basecamp#5376
4. NVIDIA GPU system lockups on media-heavy sites
- Add NVIDIA-specific environment variables for Wayland stability
- Add chromium flags installer for NVIDIA GPU optimization
- Helps prevent DMA allocation errors and system lockups
- Fixes: basecamp#5372
c7abbdd to
ffcde4d
Compare
|
This PR is superseded by #5422 which combines all fixes with proper Copilot review feedback addressed. Please review that PR instead. |
Summary
This PR fixes 4 bugs reported by users:
1. Power profile GUI not switching when clicked
omarchy-launch-walkerwas overriding menu arguments with defaults2. Screen sharing notification bar 'Hide' button not responding
3. Screenshot regression with hyprpicker on HDR displays
4. NVIDIA GPU system lockups on media-heavy sites
Files Changed
bin/omarchy-launch-walker- Fix argument passingbin/omarchy-cmd-screenshot- Add wayfreeze fallback for HDRdefault/hypr/apps.conf- Source new screen-sharing configdefault/hypr/apps/screen-sharing.conf- New window rules for screen sharinginstall/config/nvidia-chromium-flags.sh- NVIDIA chromium flags installermigrations/1777007316.sh- Screen sharing fix migrationmigrations/1777007317.sh- NVIDIA stability fix migrationmigrations/1777007318.sh- HDR screenshot fix migrationTesting
Please test: