unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* [rudalics@gmx.at: whitespace.el's permanent-locals]
@ 2007-03-14 18:39 Richard Stallman
  2007-03-14 21:43 ` Rajesh Vaidheeswarran
  0 siblings, 1 reply; 5+ messages in thread
From: Richard Stallman @ 2007-03-14 18:39 UTC (permalink / raw)
  To: Rajesh Vaidheeswarran; +Cc: emacs-devel

What was the reason for marking these variables as permanent?

------- Start of forwarded message -------
X-Spam-Status: No, score=1.2 required=5.0 tests=RCVD_IN_SORBS_WEB,
	UNPARSEABLE_RELAY autolearn=no version=3.1.0
Date: Tue, 13 Mar 2007 23:09:41 +0100
From: martin rudalics <rudalics@gmx.at>
MIME-Version: 1.0
To: emacs-devel <emacs-devel@gnu.org>
Content-Type: text/plain; charset=ISO-8859-15; format=flowed
Subject: whitespace.el's permanent-locals

whitespace.el has these lines:

     105:(put 'whitespace-mode 'permanent-local nil)
     110:(put 'whitespace-mode-line 'permanent-local nil)
     115:(put 'whitespace-check-buffer-leading 'permanent-local nil)
     120:(put 'whitespace-check-buffer-trailing 'permanent-local nil)
     125:(put 'whitespace-check-buffer-indent 'permanent-local nil)
     130:(put 'whitespace-check-buffer-spacetab 'permanent-local nil)
     135:(put 'whitespace-check-buffer-ateol 'permanent-local nil)
     140:(put 'whitespace-highlighted-space 'permanent-local nil)

I'd remove them.




_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-devel
------- End of forwarded message -------

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [rudalics@gmx.at: whitespace.el's permanent-locals]
  2007-03-14 18:39 [rudalics@gmx.at: whitespace.el's permanent-locals] Richard Stallman
@ 2007-03-14 21:43 ` Rajesh Vaidheeswarran
  2007-03-14 22:03   ` Miles Bader
  0 siblings, 1 reply; 5+ messages in thread
From: Rajesh Vaidheeswarran @ 2007-03-14 21:43 UTC (permalink / raw)
  To: rms; +Cc: emacs-devel

If I remember the reason correctly, it was because  wanted the ability
to toggle on/off the check for and correct the various types of
whitespaces to be on a per-buffer basis.

If this is not the preferred way of achieving that result, I'd be
happy to change it to the preferred way if you (or someone) can tell
me how to.

rv

On 3/14/07, Richard Stallman <rms@gnu.org> wrote:
> What was the reason for marking these variables as permanent?
>
> ------- Start of forwarded message -------
> X-Spam-Status: No, score=1.2 required=5.0 tests=RCVD_IN_SORBS_WEB,
>         UNPARSEABLE_RELAY autolearn=no version=3.1.0
> Date: Tue, 13 Mar 2007 23:09:41 +0100
> From: martin rudalics <rudalics@gmx.at>
> MIME-Version: 1.0
> To: emacs-devel <emacs-devel@gnu.org>
> Content-Type: text/plain; charset=ISO-8859-15; format=flowed
> Subject: whitespace.el's permanent-locals
>
> whitespace.el has these lines:
>
>      105:(put 'whitespace-mode 'permanent-local nil)
>      110:(put 'whitespace-mode-line 'permanent-local nil)
>      115:(put 'whitespace-check-buffer-leading 'permanent-local nil)
>      120:(put 'whitespace-check-buffer-trailing 'permanent-local nil)
>      125:(put 'whitespace-check-buffer-indent 'permanent-local nil)
>      130:(put 'whitespace-check-buffer-spacetab 'permanent-local nil)
>      135:(put 'whitespace-check-buffer-ateol 'permanent-local nil)
>      140:(put 'whitespace-highlighted-space 'permanent-local nil)
>
> I'd remove them.
>
>
>
>
> _______________________________________________
> Emacs-devel mailing list
> Emacs-devel@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-devel
> ------- End of forwarded message -------
>

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [rudalics@gmx.at: whitespace.el's permanent-locals]
  2007-03-14 21:43 ` Rajesh Vaidheeswarran
@ 2007-03-14 22:03   ` Miles Bader
  2007-03-14 22:20     ` Lennart Borgman (gmail)
  0 siblings, 1 reply; 5+ messages in thread
From: Miles Bader @ 2007-03-14 22:03 UTC (permalink / raw)
  To: Rajesh Vaidheeswarran; +Cc: rms, emacs-devel

"Rajesh Vaidheeswarran" <rv@gnu.org> writes:
> If I remember the reason correctly, it was because  wanted the ability
> to toggle on/off the check for and correct the various types of
> whitespaces to be on a per-buffer basis.

Just make it a normal minor mode.  I see no reason to do otherwise.

Indeed, this is exactly the sort of minor-mode which is likely to get
put into hook functions for various major-modes because the user wants
to control whitespace in that mode.  In such a case (and I think it's
the most common one) the parameters are much more likely to be
_mode_-specific rather than buffer-specific.

-miles
-- 
Somebody has to do something, and it's just incredibly pathetic that it
has to be us.  -- Jerry Garcia

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [rudalics@gmx.at: whitespace.el's permanent-locals]
  2007-03-14 22:03   ` Miles Bader
@ 2007-03-14 22:20     ` Lennart Borgman (gmail)
  0 siblings, 0 replies; 5+ messages in thread
From: Lennart Borgman (gmail) @ 2007-03-14 22:20 UTC (permalink / raw)
  To: Miles Bader; +Cc: rms, Rajesh Vaidheeswarran, emacs-devel

Miles Bader wrote:
> "Rajesh Vaidheeswarran" <rv@gnu.org> writes:
>> If I remember the reason correctly, it was because  wanted the ability
>> to toggle on/off the check for and correct the various types of
>> whitespaces to be on a per-buffer basis.
> 
> Just make it a normal minor mode.  I see no reason to do otherwise.
> 
> Indeed, this is exactly the sort of minor-mode which is likely to get
> put into hook functions for various major-modes because the user wants
> to control whitespace in that mode.  In such a case (and I think it's
> the most common one) the parameters are much more likely to be
> _mode_-specific rather than buffer-specific.
> 
> -miles


I agree. And a convenient way for the user to achive that is to use 
define-globalized-minor-mode and define his own globalized version of 
the minor mode.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [rudalics@gmx.at: whitespace.el's permanent-locals]
       [not found] <E1HRewG-0006my-BH@fencepost.gnu.org>
@ 2007-03-24 10:23 ` martin rudalics
  0 siblings, 0 replies; 5+ messages in thread
From: martin rudalics @ 2007-03-24 10:23 UTC (permalink / raw)
  To: rms; +Cc: Rajesh Vaidheeswarran, emacs-devel

> I failed to notice that the property being put on is nil, not t.
> These put calls are no-ops, since nil is the default.
> So it is fine if someone deletes them.

I removed them.

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2007-03-24 10:23 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-03-14 18:39 [rudalics@gmx.at: whitespace.el's permanent-locals] Richard Stallman
2007-03-14 21:43 ` Rajesh Vaidheeswarran
2007-03-14 22:03   ` Miles Bader
2007-03-14 22:20     ` Lennart Borgman (gmail)
     [not found] <E1HRewG-0006my-BH@fencepost.gnu.org>
2007-03-24 10:23 ` martin rudalics

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).