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

Deserialization Support / Defined Layouts #180

Closed
Kryan90 opened this issue Jul 31, 2019 · 6 comments
Closed

Deserialization Support / Defined Layouts #180

Kryan90 opened this issue Jul 31, 2019 · 6 comments

Comments

@Kryan90
Copy link

Kryan90 commented Jul 31, 2019

In chunkwm, I had serialized a few layouts and would de-serialize them with skhd.

Is a similar function supported in yabai?

If not, is there a standard way of achieving a desired layout?

This is an example of one of saved layouts:
Browser full length on the left, editor and terminal stacked on the right
Screen Shot 2019-07-31 at 3 42 53 PM

@koekeishiya
Copy link
Owner

There is no layout serialization or deserialization system and I don't plan on implementing one. You could maybe do something using the signal system to automate your layout.

@Kryan90
Copy link
Author

Kryan90 commented Aug 1, 2019

Ah, okay. I will read the signal docs and see if I can come up with a solution.

Thanks!

@dominiklohmann
Copy link
Collaborator

dominiklohmann commented Aug 2, 2019

What's needed for both this and #184 is this:

  • parent-window / child-windows attributes in window queries so the tree can be traversed in the correct order
  • split-ratio attribute in window queries
  • a command for setting the split-ratio directly, e.g. yabai -m window [<sel>] split_ratio <value>

Edit:

@Kryan90 If not, is there a standard way of achieving a desired layout?

Easiest is to just resize the windows using the cursor. The splits will be adjusted accordingly.

@koekeishiya
Copy link
Owner

I'm currently not interested in making the aforementioned changes.

@choco
Copy link

choco commented Oct 15, 2019

Hello, in the process of migrating from chunkwm I noticed that this feature is missing, any particular reason? I find it extremely useful in some situations.

Would this be something you'd like to get contributed?

@koekeishiya
Copy link
Owner

any particular reason?

I've opted not to implement it because the version in chunkwm feels like an incomplete solution as it is unable to track windows. I did experiment with that in chunkwm, but was not all that happy with that attempt, and I just haven't had the time to iterate on the problem yet.

I'm open to a contribution to such a system in general, but not if it is simply a copy of the existing version chunkwm had. I still think this can be solved in a much better way, given enough time spent.

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

4 participants