indenting with tabs

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

 



Karl Dahlke writes:
>A downer on tabs if you go 5 or 6 levels in,
>is that even a modest line gets cut into many pieces by the 80 column limit,

The Linux kernel exceeds that 80-column limit in many places,
and it is not too annoying to sighted users with 80-column 
displays _if_ it does not happen with too many lines.

It's when most of the lines in a function exceed the limit
or when 10 lines in a row do that it becomes too annoying.

I'm a sighted user with an 80-column display.  (I use the
Linux in text mode on a old, small monitor.)


>and that's pretty goofy.
>I know, I know, properly structured code doesn't go
>5 or 6 levels in, I know, but the code that I write in a hurry,
>that I'm not paid to write, sometimes does that.
>That's just the way it is.
>
>Another problem with the tabs, assuming the sighted person might have the
>freedom to change the spacing thereof, is that tabs are also used
>in the middle of a line, to push a short comment off to the right.
>This will get mucked up if the user changes tab = 4 for a lesser indent.
>Well, you know, I don't think people change their tab settings
>very often, so I'm not going to worry about that.
>The benefits of single-char tabs on the left kinda win the day, I think.
>
>So here is my revised .indent.pro file for comment.
>I would like to get this right, or at least reasonably satisfactory
>to a wide majority, then get on with my life.
>As you see, I had no luck getting -ci0 to work.
>That's the second "problem" with indent in only 20 minutes.
>Guess everyone just runs indent -gnu and doesn't check these things out.
>Well, with its faults, it's still the best program for the job,
>kinda like democracy.
>
>// leave blanklines alone!
>-nsob
>-ncdb
>-nbad
>-nbap
>-nbbb
>// Measure levels of indenting - use 8 spaces = one tab
>// The sighted user can set tab to anything he likes,
>// and I don't have to listen to a mix of tabs and spaces, or many spaces,
>// if I want to discern the indent level.
>-ut
>-ts8
>-i8
>-bli0
>-cbi0
>-nlp
>// I really want -ci0, but that doesn't work!
>// So I'm settling for ci3, which acts like -lp when an if statement
>// is involved, and those are the ones that are usually long anyways.
>-ci3
>-ip0
>-pi0
>-cli0
>-di2
>// Braces are set by the coding standards of the linux kernel
>-br
>-brs
>-cdw
>-ce
>-bs
>// Breaking long lines.
>-l80
>-hnl
>-psl
>-nbbo
>// Inserting spaces - usually I don't want it
>-nprs
>-npcs
>-ncs
>// can't prevent the space in switch (x)
>-nsaf
>-nsai
>-nsaw
>// the space in while(x--) ; is a good thing
>-ss
>
>Karl Dahlke
>
>_______________________________________________
>Blinux-develop mailing list
>Blinux-develop@xxxxxxxxxx
>https://www.redhat.com/mailman/listinfo/blinux-develop


[Index of Archives]     [Linux for the Blind]     [Fedora]     [Kernel List]     [Red Hat Install]     [Red Hat Watch List]     [Red Hat Development]     [Gimp]     [Yosemite News]     [Big List of Linux Books]