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

Handling of ignored windows. #7

Open
sdhand opened this issue Mar 14, 2016 · 3 comments
Open

Handling of ignored windows. #7

sdhand opened this issue Mar 14, 2016 · 3 comments

Comments

@sdhand
Copy link
Owner

sdhand commented Mar 14, 2016

@ix mentioned that he had some trouble with the way handling ignored windows works when attempting to switch from wmutils.
The exact issue happened when making a focus changing script. As listing the mountpoint shows every window, including ignored ones (overrride_redirect = true), and unmapped windows. This means when finding a new window to focus, instead of just picking the next id from the list he had to first go and check if that window was unmapped or ignored, and if it was, go and get a new id. Obviously this is quite a lot of messy code for something that should arguably be fairly simple. Contrast this to wmutils, where you can choose to list every window, just windows which aren't unmapped or ignored or only windows which are. I was wondering if would be possible to make this sort of thing easier, and am interested in hearing people's point of view on the matter.

As far as I see we have 3 options:

  1. Leave it working how it does - people just have to go and check the mapped and ignored files when doing something like this.
  2. Make ignored (and possibly unmapped windows) hidden. This would achieve something similar to what wmutils has, except it has the downside that not all windows can be accessed from /0xXXXXXXXX and when interacting with a certain window you would first have to work out if you needed to access it using /<winid> or /.<winid>.
  3. Don't include ignored windows in the list at all. The override_redirect flag is for telling the wm not to interfere with the window, and we should respect this by making it impossible. This still leaves us with the problem of what to do with unmapped windows however.

If anyone has any strong opinions on which option to go for, or any other ideas, please tell me.
Thanks.

@ralsei
Copy link
Contributor

ralsei commented Mar 15, 2016

Perhaps have dirs for each category:

$X11FS/all - All windows (override_redirect yes, unmapped, etc)
$X11FS/mapped - All mapped windows (with no override_redirect either)
$X11FS/unmapped - All unmapped windows (with no override_redirect)
$X11FS/override - Windows with override_redirect set

@sdhand
Copy link
Owner Author

sdhand commented Mar 15, 2016

This seems like a good solution. Will attemt to implement it, perhaps using symlinks from the other dirs to $X11FS/all. I'll leave this issue open until this is implemented, thanks for your help.

@halfwit
Copy link

halfwit commented Mar 16, 2016

I really prefer this to other solutions so far that I've brainstormed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants