David Kastrup <[EMAIL PROTECTED]> writes:

> Ralf Angeli <[EMAIL PROTECTED]> writes:
>
>> * David Kastrup (2006-07-14) writes:
>>
>>> But to save the user the work of rescanning the buffer after a change
>>> of the parsing variables seems a bit pointless.
>>
>> Not if you want to spare the user having to think about rescanning the
>> buffer.  That's one thing less the user has to care about.  Is there a
>> reason not to be as userfriendly as possible if that's achievable with
>> moderate effort?
>
> I consider it not userfriendly to double the amount of variables he
> has to look for.  If we want to save the user the trouble of applying
> his changes manually to existing buffers after customization, we can
> use an appropriate setter function.

Something like

(defun TeX-local-list-setter (var value)
  (let ((old (symbol-value var)) tail)
    (dolist (buffer (buffer-list))
      (when (local-variable-p var buffer)
        (with-current-buffer buffer
          (setq tail (symbol-value var))
          (while (consp tail)
            (if (eq (cdr tail) old)
                (progn
                  (setcdr tail value)
                  (setq tail nil))
              (setq tail (cdr tail))))))))
  (custom-set-default var value))
               

>
> If the only thing that we have to cater for is "customize", I don't
> think we need duplicate local variables.

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum


_______________________________________________
auctex-devel mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/auctex-devel

Reply via email to