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

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

Re: change spaces indent in text mode?


From: Jorgen Grahn
Subject: Re: change spaces indent in text mode?
Date: 6 Feb 2010 08:21:45 GMT
User-agent: slrn/pre0.9.9-111 (Linux)

On Sun, 2010-01-31, Suvayu Ali wrote:
> Hi,
>
> On Friday 29 January 2010 11:39 AM, Teemu Likonen wrote:
>> * 2010-01-29 11:28 (-0800), Brendan Miller wrote:
>>
>>> When I hit tab in text mode, it indents by 5 spaces. How do I change
>>> that? Setting tab-width doesn't seem to do the right thing.
>>
>> TAB key in text-mode indents to the columns of previous line's words. If
>> you want to go to next tab stop, as defined in tab-stop-list variable,
>> use M-i. For example, first write a line like this:
>>
>>      Here     are    some                     words.
>>
>> Then press TAB key a couple of times on the next line. Then go to the
>> beginning of line and press M-i a couple of times. You should see the
>> difference.
>
> Maybe this is a little off-topic, but is their anyway to have that 
> behaviour of the TAB key with source code, say C++ or Python? I would 
> like to align various similar consecutive lines to make them easy to 
> read. Thanks for any suggestions.

Do you have any examples where the default Emacs indentation for C++
and Python isn't readable enough? I'm asking because "align various
similar consecutive lines" is one of the things those indentation
modes do already.

As a source code reader (and maintainer) I appreciate when the
indentation I see follows one of the built-in styles (and
indent-widths) so I can edit it without having to manually tweak my
indentation to keep in style.

/Jorgen

-- 
  // Jorgen Grahn <grahn@  Oo  o.   .  .
\X/     snipabacken.se>   O  o   .


reply via email to

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