omarchy icon indicating copy to clipboard operation
omarchy copied to clipboard

Add custom walker-based share picker with monitor descriptions

Open hoblin opened this issue 2 months ago • 11 comments

Problem

The current Qt-based hyprland-share-picker has several issues that don't align with Omarchy's design:

  1. Generic labels: Shows "Screen 0", "Screen 1", "Screen 2" instead of actual monitor names, making it hard to identify which monitor to share on multi-monitor setups
  2. Takes half the screen: The Qt dialog is unnecessarily large and intrusive
  3. Doesn't support themes: Uses Qt's default styling which looks out of place in Omarchy
  4. No keyboard navigation: In a keyboard-centric system like Omarchy, you can't search or quickly select with the keyboard

Solution

This PR adds a custom walker-based share picker that:

  • Shows friendly monitor names from Hyprland descriptions
  • Compact and themeable - Uses walker's dmenu mode, integrates with Omarchy themes
  • Fully keyboard-driven - Search and select with keyboard, matching Omarchy's workflow
  • Supports all features - Screen/Window/Region selection with restore token support

Before (Qt picker)

screenshot-2025-10-07_20-20-41

After (Walker picker)

screenshot-2025-10-07_20-14-30 screenshot-2025-10-07_20-15-33 screenshot-2025-10-07_20-16-12

Implementation

  • Script: bin/omarchy-hyprland-share-picker - Custom picker using walker
  • Config: default/hypr/xdph.conf - Configures xdg-desktop-portal-hyprland
  • Migration: Copies config to ~/.config/hypr/xdph.conf

Benefits

  1. No extra dependencies - Uses hyprctl
  2. Omarchy consistency - Matches walker-based design language
  3. Better UX - Searchable, keyboard-driven, clear monitor identification

Context

PR #144 proposed a similar wofi-based picker but was closed

The Qt picker comes from upstream xdg-desktop-portal-hyprland

hoblin avatar Oct 07 '25 18:10 hoblin

This looks gorgeous! And just what I worked on today. I had the issue, that the screen picker always was showing up twice, whenever I shared the screen. I could work around by setting the Allow a restore token by default, which did the trick. I documented it here: https://www.ssp.sh/brain/screen-sharing-on-wayland-hyprland-with-chrome/

But my next stance was to try to change the eDP and DP-1, as I never know which one is my monitor. I couldn't figure it out. But This looks like a straight forward solution, and looks gorgeous. And everything with the keyboard. Thanks for sharing! If that does not have any side effects, so I couldn't share anymore in certain apps, I'll definitely use this.

sspaeti avatar Oct 07 '25 20:10 sspaeti

In fact, it does fire several times when I tested it with Google Meet. I believe the reason is that it requests access the first time to render a preview in the screen sharing UI itself, and then the second time for the actual call. This is my theory because in Discord and OBS Studio, I did not have this problem. But I would lie if I said that I dug deep into this issue.

hoblin avatar Oct 07 '25 20:10 hoblin

I've created this package https://aur.archlinux.org/packages/xdph-dmenu-sharepicker a while back. it lets you use any dmenu not just walker.

abenz1267 avatar Oct 08 '25 18:10 abenz1267

Nice ! I was thinking thinking about doing similar PR :)

vaqMAD avatar Oct 08 '25 20:10 vaqMAD

It broke after update to Omarchy 3.1.1 so I need to fix it.

hoblin avatar Oct 21 '25 07:10 hoblin

Opened a PR to make it work with the latest version of Omarchy here 👍️ https://github.com/hoblin/omarchy/pull/1

t4t5 avatar Nov 05 '25 10:11 t4t5

Thanks @t4t5 Merged and marked as ready for review.

hoblin avatar Nov 05 '25 11:11 hoblin

I don't really like the multi-step approach. Have you tested the script I shared above? Isn't that... less cumbersome?

abenz1267 avatar Nov 05 '25 12:11 abenz1267

Have you tested the script I shared above?

No, I didn't. Sorry, a little busy. My primary concern is additional dependencies that make it less stable. In the way it is implemented, the only dependencies we use are those that already exist in Omarchy.

hoblin avatar Nov 07 '25 10:11 hoblin

Have you tested the script I shared above?

No, I didn't. Sorry, a little busy. My primary concern is additional dependencies that make it less stable. In the way it is implemented, the only dependencies we use are those that already exist in Omarchy.

it's not a dependency. it's a dmenu script. literally just bash.

abenz1267 avatar Nov 07 '25 10:11 abenz1267

I wished to have this one in! The default hyprland-share-picker really kills the vibe. It's like if grandma was dressed in a trash bag and showing up in a fashion show...

NicolasDorier avatar Nov 26 '25 13:11 NicolasDorier