Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #82027
| Date | 2014-12-06 10:47 +1100 |
|---|---|
| From | Cameron Simpson <cs@zip.com.au> |
| Subject | Re: Tabs for indentation & Spaces for alignment in Python 3? |
| References | <548231be$0$12986$c3e8da3$5496439d@news.astraweb.com> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.16643.1417825192.18130.python-list@python.org> (permalink) |
On 06Dec2014 09:29, Steven D'Aprano <steve+comp.lang.python@pearwood.info> wrote: >Cameron Simpson wrote: >> I have spent too much time reading files indented >> with TABs by people using a different tabwidth to my own, and thus looking >> aweful on my screen. The original author didn't choose to make it awful, >> but their tabs rendered in my tab scheme look awful. And doubtless vice >> versa. The root cause of this is that when we, as humans, indent with >> tabs, we do it to achieve a certain visual effect; as though a certain >> number of spaces were in play. > >How is this different from people who achieve a certain visual effect by >indenting with actual spaces? > >I've seen people indent with 8 spaces. I've seen people indent with 2 >spaces. I've even seen people indent with a single space per level. I >haven't seen anyone indent with 17 spaces, but I suppose it's only a matter >of time... > >I don't see how reading code indented with tabs configured for 8/4/2/1 >spaces is *worse* than reading tab indented with 8/4/2/1 spaces. Because the author will have chosen a scheme not too insane. But when I pull up their indented-with-2-or-4-tab files in my tab==8 editor, it looks terrible. When I pull up their indented-with-spaces in whatever scheme, it looks as good or bad as their judgement, which even when tasteless is usually better than overwide tabs. I would rather not have to readjust my editor's tab spacing every time I load up a file from someone-who-is-not-me. If they use spaces, I don't have to. If they use tabs and do not indent like I do, I have to to keep things readable. Cheers, Cameron Simpson <cs@zip.com.au> They shouldn't get any new nuclear weapons until they've used the ones they've got. - Murff
Back to comp.lang.python | Previous | Next — Previous in thread | Find similar | Unroll thread
Re: Tabs for indentation & Spaces for alignment in Python 3? Cameron Simpson <cs@zip.com.au> - 2014-12-06 07:37 +1100
Re: Tabs for indentation & Spaces for alignment in Python 3? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2014-12-06 09:29 +1100
Re: Tabs for indentation & Spaces for alignment in Python 3? Cameron Simpson <cs@zip.com.au> - 2014-12-06 10:47 +1100
csiph-web