Want to read Slashdot from your mobile device? Point it at m.slashdot.org and keep reading!

 



Forgot your password?
typodupeerror
×
Microsoft Programming

Visual Studio 2010 Forces Tab Indenting 390

An anonymous reader writes "For years, Microsoft has allowed Visual Studio users to define arbitrary tab widths, often to the dismay of those viewing the resultant code in other editors. With VS 2010, it appears that they have taken the next step of forcing tab width to be the same as the indent size in code. Two-space tabs anyone?"
This discussion has been archived. No new comments can be posted.

Visual Studio 2010 Forces Tab Indenting

Comments Filter:
  • by Foredecker ( 161844 ) * on Sunday January 24, 2010 @11:26PM (#30885938) Homepage Journal

    This tab thing makes Slashdot front page and the following didnt? Windows 7 way hotter than Vista off the line, now more popular than all OS X versions [engadget.com]. Okay then...

    How is this tab things news or interesting at all? Here is what Brittany Behrens a PM for the editor team said:

    Hi Brien,

    Thank you for logging this issue. Before making this change we solicited feedback on the decision to combine Tab Size and Indent Size from a wide variety of sources, including public blog posts and forum threads, and found that the vast majority of user feedback was in favor of combining the two. If its seriously impacting your code to have Tab Size always equal Indent Size, it is possible to write a short editor extension to override the Tools->Options dialog and set the two options separately. If thats something youd be interested in, please let me know and Ill see about posting sample code for how to do this.

    Im resolving this issue as By Design because we intentionally combined these options for VS 2010, but please feel free to post again here if you have any further questions or comments and well be happy to help.

    Thanks for trying Visual Studio 2010 Beta 2 and sending your feedback!

    Brittany Behrens

    Program Manager, VS Platform - Editor

    (bolding above mine for emphasis)

    Gee, the team solicited comments, did some research and made a change that people wanted. Of course, any change will make somebody unhappy.

    Brittany even volunteered to give folks a simple editor extension to make the settings different for those that want it. My assumption is that anyone using Visual Studio is a developer and capeable of using such an extension, or writing it themselves. It is not difficult.

    -Foredecker

    • by j741 ( 788258 ) on Sunday January 24, 2010 @11:33PM (#30885978) Journal

      This tab thing makes Slashdot front page and the following didnt?

      Windows 7 way hotter than Vista off the line, now more popular than all OS X
      versions

      Of course id did; it's a developer tool so it immediately has street cred at /.
      Everything else that has nothing to do with coding or Linux is immediately a 3rd rate info byte unworthy of these hallowed pages ;->

    • by black3d ( 1648913 ) on Sunday January 24, 2010 @11:43PM (#30886024)

      This tab thing makes Slashdot front page and the following didnt?

      Windows 7 way hotter than Vista off the line, now more popular than all OS X
      versions

      It's kdawson's shift. He'll never post any article that's even mildly favorable of anything Microsoft related. However, if you can find a story that says some kid in Sweden doesn't like the Windows 7 box-colors, you've got yourself a kdawson front-pager! :)

    • by Wumpus ( 9548 ) <IAmWumpus AT gmail DOT com> on Monday January 25, 2010 @12:06AM (#30886186)

      No.

      They solicited input from each other and in a blog post that generated a handful of responses. They did this to eliminate "a class of bugs" in the new editor that was triggered by setting the two numbers to different values. Which means they had a bunch of bugs (probably due to confusion between the two settings in the code) and someone had the brilliant idea that the bugs will go away if they just crippled the editor in such a way that the bugs will never be triggered. They solicited input, very quietly, and did it. This also means that the workaround they offer (writing a fucking extension, for fucking crying out loud - what is this, emacs?) will trigger all those bugs because they didn't fix them.

      Idiots.

    • Nice. I'm sure you'ld prefer to have something closer to the Windows core than this, but nice first post. If you're going to advocate it pays to have front billing.

      Now if you're going to drive off course from source code formatting to operating system adoption I can be forgiven for also going wide afield.

      How's that Window Mobile thing working out for you? Have they canned Roz Ho yet for the Danger debacle? Will she have to extrapeneur to a startup and bring back its corpse to prove her loyalty, or wil

    • by Col. Klink (retired) ( 11632 ) on Monday January 25, 2010 @12:40AM (#30886440)

      Did you read the blog post [msdn.com] where they solicited feedback? It had 9 comments in total. Among them was this comment from the author of the blog (4th comment):

      I assure you we won't be changing that option [tab vs spaces] any time soon :-)

      So they solicited comments on a blog that no one reads and immediately say they aren't planning to change anything when questioned. After saying they wouldn't be changing the option, no one complained. Wow, what due diligence.

    • Do they count all of us who bought computers with Windows 7 pre-installed and then deleted it? Sure people rushed to Windows 7 - it's been a while since anyone running a PC could buy it with an OS that wasn't total crap so they could all finally get the updates they wanted. Windows PCs tend to be cheaper than Macs. Saying they outsell Macs is like saying they sell more Ford Focus's than BMW's. A PC does what a Mac does for half the price. It just doesn't look as good, work quite as well, last as long, or of
    • by cgenman ( 325138 ) on Monday January 25, 2010 @01:02AM (#30886556) Homepage

      This tab thing makes Slashdot front page and the following didn't?

      Of course the tab thing made Slashdot front page. Some people here virtually LIVE in Visual Studio, and code indentation is a heavily entrenched basic function of coding that people get surprisingly fired up about. Even if this particular aspect of code indentation isn't going to effect people, it's just begging for a heated emacs level discussion.

      Your article, on the other hand, basically confirms that people like Windows 7 more than Vista, and that Windows 7 continues the well known and understood tradition of Windows outselling OSX by a factor of 10 to 1. These are things we already knew. Also, the article you site isn't even the source of the information, but refers to a much better Ars Technica article, which itself gets the data from Net Applications. I wonder if you didn't link the Ars Technica [arstechnica.com] article directly because it claims that "Linux was the only operating system [in December] to show positive percentage growth in market share." Or maybe this one "When putting this into perspective across the whole year, though, we see that Windows was actually sliding steadily throughout 2009 (93.66 percent in January 2009), while both Mac OS (4.71 percent in January 2009) and Linux (0.90 percent in January 2009) have been gaining." Or maybe the fact that Windows XP continues to hold onto 2/3rds of the active Windows installbase.

      Also, it might be nice to point out that you're work at Microsoft in the Windows org as a development manger. It would boost your credibility as a poster, and reduce potential conflicts of interest.

  • Visual Python anyone? Doesn't Python force tabbed spacing for scoping?

    • by Blakey Rat ( 99501 ) on Monday January 25, 2010 @12:12AM (#30886244)

      Ending sentence fragments with anyone, anyone? Does anyone like this convention, anyone? Can we just see it die horribly in flames, anyone?

    • Visual Python anyone? Doesn't Python force tabbed spacing for scoping?

      1) You must mean IronPython.

      2) There's no Visual Studio integration for the current (2.x) version of IronPython. There used to be one for 1.x, but it had the status of a "sample VS language extension".

      3) Python requires indentation, but doesn't require tabs (though it supports them).

      4) Because the consequences of mixing tabs and spaces are much more nasty in Python, tabs are generally considered anathema among people who write in it.

  • It seems to me that most editors jump to the current indent level when you press tab - or if not, they should. I can't imagine many people want tabs to really go eight spaces...

    But this is why rather than using tab characters in code I've always felt editors should backfill with spaces instead of tabs (outside of editing makefiles of course!)

  • by dziman ( 415307 ) on Sunday January 24, 2010 @11:36PM (#30885988)

    FIGHT!

  • Tabs are news?

    Have you no sense of responsibility to your audience?

  • by liquiddark ( 719647 ) on Monday January 25, 2010 @12:16AM (#30886276)
    Herb Sutter once observed in relation to C++0x that when it comes to complex, interesting questions of language design, very few people are even vaguely qualified to comment, and when it comes to issues of whitespace every idiot on the planet has an opinion. And when those idiots get the chance, they'll post those issues as news on an aggregator of some sort (ok, that last part wasn't Herb Sutter).
  • For years, Microsoft has allowed Visual Studio users to define arbitrary tab widths, often to the dismay of those viewing the resultant code in other editors.

    There are editors that don't let you define arbitrary tab widths? No, seriously -- I'm not sure I've ever seen an editor that didn't provide the option, generally along with the option to have the tab key insert spaces instead of tabs, thereby avoiding that issue and the inevitable problems that arise as tabs and spaces are mixed.

    And if that doesn't work, there's this really newfangled tool called indent that you can use...

  • Plain and simple. If they standardized tabs with a quantity of space chars in all their editors then it is very, very good news. That's the only way to have consistency across all viewers/editors.

  • in cross-platform project is to force everyone to use spaces only.
    The shit that happens to code with tabs that get edited on unix and windows and different editors make the text to travel towards the right side of screen at exponentially increasing speeds.
    Add some retarded editors and direct copying of sources between unix and windows without going through source control system that converts line endings and you will also have empty lines being added as well.
    The end result is 1/100 ratio between code and wh

  • by overnight_failure ( 1032886 ) on Monday January 25, 2010 @03:16AM (#30887270)
    I know this is Slashdot an' all but really? You've got to the point where you have to bitch about tabs settings in MS's development environment. Have MS not been squishing enough small companies or something equally evvvvvvil for you lately? Quick everyone, another example of MS being a horrible overlord, they've combined tabs and indent in Visual Studio!

    *sigh*
  • by smartin ( 942 ) on Monday January 25, 2010 @08:07AM (#30888712)

    It is really unfortunate the IDE's let people change the tab setting and even more unfortunate that IDE's like Eclipse and IntellJ come with it incorrectly set to 4 spaces. This has the effect of totally buggering the code when viewed in any context other than one with the same settings. Printers and most code viewers use an 8 character tab stop.
    Yes things work fine if you forbid mixing tabs and spaces in indent but, in my experience this does not work in practice.

Ocean: A body of water occupying about two-thirds of a world made for man -- who has no gills. -- Ambrose Bierce

Working...