[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: moving window handling into lisp
From: |
martin rudalics |
Subject: |
Re: moving window handling into lisp |
Date: |
Mon, 27 Jul 2009 15:37:24 +0200 |
User-agent: |
Thunderbird 2.0.0.21 (Windows/20090302) |
> Basically keep the same window objects we have today, but allow lisp
> to get a handle on non-leaf window objects (today, AFAICT, lisp can
> only ever see leaf windows).
Elisp can "see" all internal windows. Making internal windows more
accessible was the idea underlying my proposal.
> window-children WINDOW => (LEFT-CHILD-WIN . RIGHT-CHILD-WIN)
An internal window can have more than two children (for no good reason,
BTW).
> window-parent WINDOW => PARENT-WIN
> set-window-children WINDOW LEFT-CHILD-WIN RIGHT-CHILD-WIN
`window-parent' and `window-children' would be trivial. Providing
`set-window-children' is hardly feasible IMHO. Who'd be responsible for
calculating the respective sizes?
> (etc)
>
> A brief look suggests that much of the traditional window handling
> code (`window-list', `other-window', `split-window', `delete-window',
> `delete-other-windows', etc) could then be moved into lisp; none of
> that code looks very complicated or dangerous.
The problem with `split-window' and `delete-window' is that you can
easily mess up things when you create windows that don't have the right
size. From my experience this usually makes Emacs crash pretty soon and
we shouldn't allow Elisp code crash Emacs. OTOH doing all the necessary
checks wrt window sizes in `set-window-children' would mean hard work.
It would be fine to see such code though since we could use it to safely
store window configurations on disk in a non-procedural manner.
martin, whose `switch-to-buffer' is in window.el
- moving window handling into lisp, Miles Bader, 2009/07/27
- Re: moving window handling into lisp,
martin rudalics <=
- Re: moving window handling into lisp, Lennart Borgman, 2009/07/27
- Re: moving window handling into lisp, martin rudalics, 2009/07/27
- Re: moving window handling into lisp, Lennart Borgman, 2009/07/27
- Re: moving window handling into lisp, martin rudalics, 2009/07/27
- Re: moving window handling into lisp, Lennart Borgman, 2009/07/27
- Re: moving window handling into lisp, martin rudalics, 2009/07/27
- Re: moving window handling into lisp, Lennart Borgman, 2009/07/27
- Re: moving window handling into lisp, martin rudalics, 2009/07/27
- Re: moving window handling into lisp, Lennart Borgman, 2009/07/27
- Re: moving window handling into lisp, Stefan Monnier, 2009/07/27