[Top][All Lists]

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

bug#812: frame-local-variable documentation

From: Glenn Morris
Subject: bug#812: frame-local-variable documentation
Date: Sat, 30 Aug 2008 18:56:55 -0400
User-agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/)

Nikolaj Schumacher wrote:

> As far as I can tell frame-local variables have been (or are about to
> be) removed and currently don't work.

They haven't been removed and will still be in 23.1, except:
"Variables cannot be both buffer-local and frame-local any more."

However, something seems broken. This works as it should:

emacs -Q
(setq foo 'bar)

(make-variable-frame-local 'foo)
     ; [1]
(set-frame-parameter nil 'foo t)

foo  ; -> t [2]


foo  ; -> bar in new frame, still t in old frame [3]

If you add an extra evaluation of `foo' at point [1] (after making it
frame local, but before adding a frame parameter), then at point [2]
you get 'bar rather than t. After you make a new frame, it starts
working (at [3]).

> `modify-frame-parameters' still contains this paragraph:
>> The value of frame parameter FOO can also be accessed
>> as a frame-local binding for the variable FOO, if you have
>> enabled such bindings for that variable with
>> `make-variable-frame-local'.
> That should be removed, I think.

I mentioned it's obsolete.

> `make-variable-frame-local' has this note:
>> This function is obsolete since 22.2;
>> use a frame-parameter instead.

I tweaked it.

reply via email to

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