Welcome to MSDN Blogs Sign in | Join | Help

Sara Ford's Weblog

My adventures embracing open source on CodePlex and at Microsoft

News

    • Did you know... All author proceeds go directly to sending Hurricane Katrina survivors to college.

      Microsoft Visual Studio Tips book

      Recent Entries

Did you know... You can increase and decrease the line indent from the text editor toolbar - #025

Not one of my finer tip of the day titles, but it illustrates the point.  =)

Increase Indent on Text Editor Toolbar

With either a single line or several lines selected, you can either use the Increase Indent or Decrease Indent toolbar button found on the text editor toolbar, or from Edit - Advanced menu (listed as Increase / Decrease Line Indent).

Technorati tags: ,
Posted: Wednesday, August 29, 2007 3:00 AM by saraford

Comments

Jason Haley said:

# August 29, 2007 10:02 AM

GregM said:

Is this any different that selecting the lines and using Tab or Shift-Tab?

Ah, it does make a difference when there is no selection.  When there's no selection, Tab inserts a tab at the current location, but this function indents the line.

Very cool, thanks.

# August 29, 2007 10:07 AM

s.hellewell said:

You can also select the lines and just hit tab to indent and shift-tab to de-indent (not sure if that is the right term).

# August 29, 2007 10:19 AM

PilotBob said:

I think I prefer to use TAB and SHIFT-TAB. More intuative don't ya think?

# August 29, 2007 10:31 AM

saraford said:

Yep, GregM got it.  The difference is that tab will insert a tab (or spaces) when there's no selection.  But increase and decrease indent will always indent and outdent the current line if there's no selection.

I probably just spaced on this part when i was writing the tip.  And knowing my luck, there's probably some tools options feature that modifies this behavior, but when/if i discover it, i'll link back here.

# August 29, 2007 12:56 PM

Steve Trefethen's Weblog said:

# August 30, 2007 3:29 AM

Visual Studio 2008 ワンポイント said:

あまり良いタイトルではありませんが、要点は示しています。 1 つまたは複数の行を選択した状態で、[テキスト エディタ] ツール バーの [インデント] または [インデント解除] をクリックするか、[編集]

# July 13, 2008 11:42 PM

Секреты Visual Studio said:

Не самый изящный заголовок для "Совета дня", но он полностью иллюстрирует идею =) Вы можете

# August 20, 2008 4:09 AM
New Comments to this post are disabled
Page view tracker