From: despen@verizon.net (Dan.Espen)
To: help-gnu-emacs@gnu.org
Subject: Re: Python Mode, managing and converting TABS
Date: Wed, 28 May 2014 17:17:11 -0400 [thread overview]
Message-ID: <ic1tvdpprc.fsf@home.home> (raw)
In-Reply-To: mailman.2339.1401307161.1147.help-gnu-emacs@gnu.org
Tim Johnson <tim@akwebsoft.com> writes:
> I'm currently using
> GNU Emacs 23.3.1 (x86_64-pc-linux-gnu, GTK+ Version 2.24.10 on
> Ubuntu 12.04, but expect to have to also use --no-window-system
> ("console mode") on occassion.
>
> I have used emacs extensively in the distant past (up 'til 2008), so
> am re-acquainting myself with the system.
>
> I have much legacy python code that has "hard tabs" and to meet
> the python style guides, will have to be converted to "soft tabs".
> I.E. TAB => " "
>
> I also need to configure emacs so that TAB (or Ctrl-i) inserts four
> spaces instead of the TAB character.
>
> I currently have this in my .emacs [code]
> (add-hook 'python-mode-hook
> '(lambda ()
> (turn-on-font-lock)
> (setq default-tab-width 4)
> (setq tab-width 4)
> (imenu-add-menubar-index)
> (setq imenu-sort-function 'imenu--sort-by-name)))
>
> [/code]
>
> I'd welcome any and all advice, pointers to previous discussion
> would are solicited.
To remove tabs, make the whole buffer the region:
C-x h
then run untabify:
M-x untabify
--
Dan Espen
next parent reply other threads:[~2014-05-28 21:17 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <mailman.2339.1401307161.1147.help-gnu-emacs@gnu.org>
2014-05-28 21:17 ` Dan.Espen [this message]
2014-05-28 21:44 ` Python Mode, managing and converting TABS Tim Johnson
2014-06-02 19:33 ` Damien Wyart
2014-06-03 15:20 ` Tim Johnson
[not found] ` <mailman.2841.1401808858.1147.help-gnu-emacs@gnu.org>
2014-06-03 17:53 ` Damien Wyart
2014-06-04 23:49 ` Tim Johnson
2014-05-28 19:13 Tim Johnson
2014-05-28 23:37 ` Stefan Monnier
2014-05-29 15:57 ` Tim Johnson
2014-05-29 16:49 ` Stefan Monnier
2014-05-29 17:51 ` Tim Johnson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ic1tvdpprc.fsf@home.home \
--to=despen@verizon.net \
--cc=help-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.