-
Notifications
You must be signed in to change notification settings - Fork 81
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
Layout coding: hiding a window #27
Comments
I think the window sizes have to be strictly > 0 (though I might be wrong: the XCB docs are patchy to say the least!) I do know that for the window manager check window (for setting ewmh props etc) I set the width and height to 1px each and that effectively hides the window. Might be worth trying that? If not, then I suspect I'd need to modify the layout API / pub type ResizeAction = (WinId, Option<Region>) |
I tried changing the size to (1, 1) and I noticed a thing: it was already working before! The problem actually is that the layout function doesn't seem to run when simply cycling though windows. Nonetheless, I think the unmapping of windows might be better in the future. Apparently qutebrowser crashes when its screen size is as small as 0 or 1 (still investigating) and other applications might end up having the same bug. |
@YohananDiamond are you able to check if this is what you are after? |
The problem seems to be still here - I can focus other windows other than the first one, but they are on the background. But I noticed one thing: if I switch workspaces and go back, the window that was hidden is shown. Maybe the layout is not updating on focus change? |
Ah sorry, yes you need to set the layout config to trigger follow focus like this. You probably also want to do what I've done and allow client wrapping as well (default is to allow but you need to make sure you specify it when you create the config) Layout functions by themselve can't determine when and how they are triggered: they only specify what to do with the clients when they are triggered. To be honest, at least for the default layouts I probably should provide some helper functions that bundle them with the appropriate |
Oh, okay. It's working now, thanks for the help! |
I've been trying to implement the monocle layout on penrose, and I'm stuck on how to hide windows.
The monocle layout - as far as I'm concerned - works this way: if a window is focused, it occupies the entire space reserved for the layout; and if it is not focused, it's just hidden.
I've tried to hide a window by setting its size to zero, but it doesn't seem to work. Would you happen to know what is happening?
Here's the function:
The text was updated successfully, but these errors were encountered: