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

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

Re: Indenting Emacs Lisp only with tabs?


From: Elena
Subject: Re: Indenting Emacs Lisp only with tabs?
Date: Thu, 3 Sep 2009 07:02:43 -0700 (PDT)
User-agent: G2/1.0

On 3 Set, 12:17, B Smith-Mannschott <bsmith.o...@gmail.com> wrote:
> One of the reasons we stick with monospaced fonts in programming is
> because we like to play all sorts of clever tricks with vertical
> alignment to visually group related things. (These tricks,
> incidentally, are also why mixing tabs and spaces causes so much pain
> much of the time.)

Indeed, what a mode means when it indents a line with N spaces is:
move this text under (N+1)th character of previous line. That could be
accomplished with proportional fonts, too. Modes use spaces for what
they do, not what they mean. That's why I don't think we will anything
like elastic tabstops in Emacs in the near future. Too much indenting
code depends on this low level assumption.

> But, *of course* it requires different habits when laying out code. Of
> course, an editor that supports it as well as emacs does mono-spaced
> layout would include logic to insert hard tabs at the right places to
> produce a pleasing layout, just as emacs inserts spaces to vertically
> align the arguments of a mult-line procedure call.

I think that could be eased by making tabs (that is: vertical
alignment) visible, just as I think modes for makefiles already do
(albeit not for alignment purposes).

> I think it's a clever idea, and I do think I could learn to take
> advantage of what it offers while minimizing the impact of its
> downsides, just as I do now when I code in emacs.

I agree.




reply via email to

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