Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request to disable window snapping on the top screen edge. #1765

Open
guzz46 opened this issue Apr 29, 2024 · 3 comments
Open

Feature request to disable window snapping on the top screen edge. #1765

guzz46 opened this issue Apr 29, 2024 · 3 comments
Milestone

Comments

@guzz46
Copy link

guzz46 commented Apr 29, 2024

It would be great to have an option to disable window snapping on the top screen edge while retaining it everywhere else, kwin has this option, currently when you drag a window to the top of the screen it can trigger it to maximize or horizontal snap (depending on your config setting) when you just wanted to move it to the top of the screen, thanks.

@tokyo4j
Copy link
Contributor

tokyo4j commented Apr 29, 2024

kwin has this option

I'm trying KDE Plasma.
Looks like it supports tiling a window only to left/right edges and supports maximizing a window on top edge, right?
Then a possible solution to mimic this behavior would be adding something like <snapping><disableVertical> [yes|no] and still allowing to enable <snapping><topMaximize>.
Personally I'm fine with this feature to be added since I don't usually tile a window to top/bottom edges.

I'm curious how other WMs like xfce4 handle this.

@guzz46
Copy link
Author

guzz46 commented Apr 30, 2024

Looks like it supports tiling a window only to left/right edges and supports maximizing a window on top edge, right?

Yes, you can choose to disable the top screen edge so no maximizing or snapping happens when dragging a window to the top of the screen, while retaining the ability to snap windows to the left or right and quarter snapping on every corner too, personally I think its easier to maximize a window just by double clicking on the titlebar, which labwc already supports.

From memory I don't think xfwm4 has an option to disable the top edge, I think its just edge snapping or no edge snapping.

@Consolatis
Copy link
Member

Consolatis commented May 1, 2024

I wonder if something like this would be more future-proof:

<snapping>
	<topAction>SnapToEdge|Maximize|MaximizeGaps|None</topAction>
</snapping>

Additionally we can deprecate topMaximize over the next few releases.
MaximizeGaps (or some better name) would trigger <action name="SnapToEdge direction="center" /> rather than the Maximize action.

Edit:
Or we go as far as to support something like this

<snapping>
	<topActions>
		<action name="Maximize"  />
	</topActions>
	<leftActions>
		<action name="SnapToEdge" direction="left" />
	</leftActions>
	<rightActions>
		<action name="SnapToEdge" direction="right" />
	</rightActions>
	<bottomActions>
		<action name="SnapToEdge" direction="down" />
	</bottomActions>
</snapping>

However that would be slightly annoying for the overlays, could still be done by parsing the actions before deciding how to draw the overlay though.

@Consolatis Consolatis added this to the 0.7.3 milestone May 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants