Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re^2: No Hard Tabs in Code

by Xiong (Hermit)
on Jul 01, 2010 at 23:22 UTC ( #847644=note: print w/replies, xml ) Need Help??


in reply to Re: No Hard Tabs in Code
in thread No Hard Tabs in Code

Changing the indent level is rarely an issue. I have Increase Indent, Decrease Indent set to Ctrl-[, Ctrl-], because that's how BBEdit does it.

Getting tokens internal to a line to start exactly on tab stops is sometimes a bit trickier, without using hard tabs. On the other hand, it's often more important to match orthogonal syntax to the previous line, so spaces are better there anyway. I'm sold.

- the lyf so short, the craft so long to lerne -

Replies are listed 'Best First'.
Re^3: No Hard Tabs in Code
by ikegami (Pope) on Jul 01, 2010 at 23:43 UTC

    Getting tokens internal to a line to start exactly on tab stops is sometimes a bit trickier, without using hard tabs.

    I don't know what you mean. Not only does auto-indenting handle that in almost all situations, the tab key of my editors bring me to a tab stop (even though it's configured to do so by adding spaces).

      Given:

      a line1 a line2

      ...and the desired result:

      a line1 a line2

      ...where only spaces intervene; I do not know of any way to align with a single keystroke. If hard tabs are used, a single backspace aligns.

      That was my argument. I hope I've made it clear that I no longer find it compelling.

      - the lyf so short, the craft so long to lerne -

        Wait, you're saying you're using tabs mid line? ow! Your code will look like garbage if the viewer uses different tab stops. I don't mind doing some extra work to avoid that.

        It's also a big time waster and distraction to have to pause after each press of Del or cursor to see how far the cursor has moved. I can delete 10 spaces faster than I can delete 10 columns that may contain tabs.

        Personally, I often come from the left and use Ctrl-Del (delete to character or EOL) since it's usually more natural to come from the left in the situations in which such an operation is done.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://847644]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (5)
As of 2021-10-20 20:45 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My first memorable Perl project was:







    Results (82 votes). Check out past polls.

    Notices?