help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Using only one emacs session


From: Pascal J. Bourguignon
Subject: Re: Using only one emacs session
Date: Sun, 17 May 2009 01:05:01 +0200
User-agent: Gnus/5.1008 (Gnus v5.10.8) Emacs/22.3 (darwin)

Francis Moreau <francis.moro@gmail.com> writes:

> On May 16, 5:43 pm, p...@informatimago.com (Pascal J. Bourguignon)
> wrote:
>> Francis Moreau <francis.m...@gmail.com> writes:
>> > yes, that's one possibility I did evaluate. But the main concern is
>> > that I don't know how to get a list of all registers with a
>> > description for each.
>>
>> Then why don't you ask emacs how to get a list of all registers with a
>> description for each?
>>
>
> Well the result is quite bad:
>
>    Register a contains a window configuration.
>    Register b contains a window configuration.
>    Register c contains a window configuration.
>
> which is not very useful IMHO.

The results are better for other kinds of register contents.

But if you're not happy with this result, why don't you patch it?


The problem here is that window-configuration are opaque objects.

We have about only three functions: 
  (current-window-configuration) to get the current window configuration
  (set-window-configuration wc)  to set the window configuration and
  (compare-window-configuration wc1 wc2) to compare them.
and these functions are implemented in C.  

You have two solutions:

If you want to have accessors  to get details about eg. the windows in
a given window configuration, you would have to patch the C code of
emacs.  Untasty, but it would probably be the best solution.

An alternative would be to put an advice on
window-configuration-to-register.  This advice would collect whatever
information about the current window configuration you may like to
report in the register list, (eg. a list of the displayed buffer
names), and associate it to the window-configuration so it can be
displayed by list-register.



> Other things (perharps more important) that make window package
> superior is that it allows me to use some window navigation 'a la' gnu
> screen (go back and forth between the 2 most recent visited windows,
> go to the next/previous window, select a window among a list of well
> described window etc...).

I don't know what "window package" is, so I cannot comment, but it
seems to me that these features are already present in emacs, or
easily added.

-- 
__Pascal Bourguignon__


reply via email to

[Prev in Thread] Current Thread [Next in Thread]