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

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

Re: whitespace-cleanup + untabify?


From: Rupert Swarbrick
Subject: Re: whitespace-cleanup + untabify?
Date: Sat, 14 Jun 2008 16:02:21 +0100
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.2 (gnu/linux)

"dsevilla@gmail.com" <dsevilla@gmail.com> writes:

> Dear all:
>
> I'm a no tab person. I would like my whitespace-cleanup command to
> also perform an untabify. How can this be done? I haven't found any
> option that connects untabify and whitespace-cleanup. I'm using:
>
> GNU Emacs 23.0.60.1 (i486-pc-linux-gnu, GTK+ Version 2.12.9)
>
> I would really appreciate the help.
>
> Regards,
> diego.

I hope I've understood the problem correctly: it seems you want a
command to run whitespace-cleanup and untabify on the current
buffer. As far as I know such a command doesn't exist...

(defun both-cleanups ()
  (interactive)
  (untabify (point-min) (point-max))
  (whitespace-cleanup))

... well, it does now!

I must admit I've never used whitespace-cleanup before, and can't get
it to do anything! But that applies to calling it manually too, so I
presume this will work ok for you.

You probably want to give it a better name and/or a keybinding.

Rupert


reply via email to

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