Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. Tabs vs Spaces

Tabs vs Spaces

Scheduled Pinned Locked Moved The Lounge
visual-studiohelpquestion
63 Posts 43 Posters 130 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • O obermd

    I think it had to do with what a mechanical typewriter was able to reliably insert. Remember, the tab key didn't shift x spaces, it shifted to the next tab stop, and yes, these were physical stops in a mechanical typewriter. Since these old machines worked on a fixed width font of 8 characters per inch and the physical tab stops were one inch apart, a tab became associated with 8 characters.

    S Offline
    S Offline
    svella
    wrote on last edited by
    #61

    Typewriters were typically either 10 (Pica) or 12 (Elite) characters per inch. Some of the later typewriters could support either and had swappable type balls.

    1 Reply Last reply
    0
    • K Kevin Marois

      Quick survey... How many of you uses tabs vs spaces to indent your code?

      If it's not broken, fix it until it is. Everything makes sense in someone's mind. Ya can't fix stupid.

      B Offline
      B Offline
      Br Bill
      wrote on last edited by
      #62

      FINALLY someone has brought up this subject!

      1 Reply Last reply
      0
      • K Kevin Marois

        Quick survey... How many of you uses tabs vs spaces to indent your code?

        If it's not broken, fix it until it is. Everything makes sense in someone's mind. Ya can't fix stupid.

        U Offline
        U Offline
        UziTech
        wrote on last edited by
        #63

        I think this thread nicely illustrates why tabs should be used for indentation. You want 2, 4, 8 character indentation, fine. You want half inch indentation, fine. You want 2½ character indentation, %#*$ you, but sure. No one has to choose what is the "right" amount, everyone's editor will display it how they want.

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups