Hyprland icon indicating copy to clipboard operation
Hyprland copied to clipboard

Enhancement: Allow windows in the special workspace to go full screen (scratchpad)

Open Zeioth opened this issue 1 year ago • 9 comments

Currently, trying to make a window full screen while in the special ws, will do nothing.

Zeioth avatar Apr 28 '23 09:04 Zeioth

no why

vaxerski avatar Apr 28 '23 14:04 vaxerski

Any type of window (pinned, floating, or special workspace) should be fullscreenable.

Rationale:

  • I put my dropdown terminal in the special workspace. Sometimes I want it to maximize it temporarily, and then unmaximize it when done.
  • When I have a pinned floating PiP video that I am watching across workspaces, I occasionally want to fullscreen it when something interesting is happening, and hide it (via special workspaces) when I want to focus on my work.

c.f. tmux's pane zoom is intended for a very similar use case.


P.S. Dropdown terminal config:

bind = $mod, grave, togglespecialworkspace, dropdown
exec-once = alacritty --class dropdown -e tmux new-session -A -s 0

windowrulev2 = float, class:^dropdown$
windowrulev2 = workspace special:dropdown, class:^dropdown$
windowrulev2 = size 99% 50%, class:^dropdown$
windowrulev2 = move 0.5% 0%, class:^dropdown$

YodaEmbedding avatar May 02 '23 12:05 YodaEmbedding

@YodaEmbedding did you find any work around for this? I do have same kind of setup for my floating terminal and indeed time to time I use it as full screen.

marianozunino avatar Sep 11 '23 00:09 marianozunino

@marianozunino I ended up switching back to i3 since (i) I missed the flexibile design of i3 "scratchpads" in comparison with Hyprland special workspaces, and (ii) Wayland is missing OBS window recording and Zoom screenshare support. It was a worthwhile experiment, though, since I brought back some new ideas and theming into my revised i3/polybar configs. These were my Hyprland special workspace bindings at the time.

Perhaps one workaround might involve writing some hacky scripts to intelligently fullscreen a given window and unpin/unspecial it temporarily, and restoring the window states when defullscreening.

YodaEmbedding avatar Sep 11 '23 01:09 YodaEmbedding

iirc downgrading obs to 29.0.2 used to fix window sharing

MightyPlaza avatar Sep 11 '23 01:09 MightyPlaza

I'm on obs 29.1.3 and window sharing works first try with the recent XDPH rewrite. Can't say anything about zoom though, but even webcord with electron24 can't screenshare.

tchofy avatar Sep 11 '23 01:09 tchofy

#!/bin/sh
function get_kitty() {
    # hyprctl clients -j | jq -r '.[] | select(.class == "kitty") | .address'
    hyprctl clients -j | jq '.[] | select(.class == "kitty")'
}

active_workspace="$(hyprctl activeworkspace -j | jq -r '.id')"
kitty="$(get_kitty)"
kitty_address="$(echo $kitty | jq -r '.address' )"
kitty_workspace=$(echo $kitty | jq -r '.workspace.id' )

if [ "$kitty_address" == "" ];
then
    kitty &
else
    kitty="$(get_kitty)"
    kitty_address="$(echo $kitty | jq -r '.address' )"
fi

if (($active_workspace == $kitty_workspace))
then
    hyprctl dispatch movetoworkspacesilent "name:terminal,address:$kitty_address"
else
    hyprctl dispatch movetoworkspace "$active_workspace,address:$kitty_address"
    hyprctl dispatch focuswindow "address:$kitty_address"
    hyprctl dispatch resizeactive "exact 80% 80%"
    hyprctl dispatch centerwindow
fi

I've made a script to emulate the scratchpad and yet with the ability to make it fullscreen in case anybody could need it

c3n21 avatar Nov 26 '23 11:11 c3n21

I would like to add my use case where full screen in special workspace would be handy.

I put all messenger apps in special:messaging workspace. Sometimes I've got media files in messages which are being opened by default in dedicated fullscreen window just to be closed.

Now I am not able to check these media files in fullscreen which is annoying and breaks UX design of those messenger apps.

UPD: also if wlogout is called from special workspace it opens windowed and it looks ridiculous 🙃

ArkadyBuryakov avatar Feb 05 '24 20:02 ArkadyBuryakov

my use cases for maximized clients in special workspace:

  • fullscreen for Windows KVM virtual machine
  • maximized and groupped messenger-clients

fedoranvar avatar Feb 16 '24 05:02 fedoranvar