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

respectsizehintsrule patch #338

Open
apprehensions opened this issue Feb 8, 2023 · 7 comments
Open

respectsizehintsrule patch #338

apprehensions opened this issue Feb 8, 2023 · 7 comments

Comments

@apprehensions
Copy link

SIZEHINTS_RULED_PATCH doesn't seem to work for me, i want to obey all sizehints for all windows EXCEPT st, so i don't have to use anysize patch for st.

@bakkeby
Copy link
Owner

bakkeby commented Feb 8, 2023

I don't think that you can get around using the anysize patch for st. Any particular reason why you don't want that?

@apprehensions
Copy link
Author

apprehensions commented Feb 8, 2023

so i can have pixel accurate resizing in floating mode

@bakkeby
Copy link
Owner

bakkeby commented Feb 9, 2023

The only thing you need from the anysize patch is:

-	sizeh->height_inc = win.ch;
-	sizeh->width_inc = win.cw;
+	sizeh->height_inc = 1;
+	sizeh->width_inc = 1;

The rest is all about centering the content of the window depending on the remaining space, which can make it look like it is swimming inside the window when you resize it.

@apprehensions
Copy link
Author

so is the patch gonna be implemented or not though, if not you can gracefully just close this issue.

@bakkeby
Copy link
Owner

bakkeby commented Feb 12, 2023

Oh, so this issue is asking if the respectsizehintsrule patch can be integrated into dwm-flexipatch? You could have made that more clear.

If you had tried that patch out before asking then you would have found that this also does not solve your problem.

@apprehensions
Copy link
Author

also does not solve your problem.

i respect all sizehints except st's sizehints via rules.

@bakkeby
Copy link
Owner

bakkeby commented Feb 12, 2023

In dwm you have that windows are generally in one of two states; they are either tiled, or they are floating.

A stock dwm has the following config.

static const int resizehints = 1;    /* 1 means respect size hints in tiled resizals */

This being set to 1 means that dwm will respect a window's size hints also when tiled. Setting this value to 0 means that size hints for windows are ignored when the window is tiled. What this means is that size hints are always respected for floating windows.

When it comes to respectsizehintsrule it was just an example patch showing how control that same setting on a per client basis using client rules. As in, it only affects whether size hints are respected for tiled windows - size hints for floating windows are always respected.

What you are trying to do here is to explicitly disrespect size hints for a particular window when floating.

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

2 participants