7

I just made the jump from VS2010 to VS2013 and have encountered an odd bug/feature with no apparent workaround.

In VS1010 I'm accustomed to clicking "Go to Definition" on the context menu above a highlighted class so as to open the relevant .cs file in a new tab.

VS2013 has this same feature but for some incomprehensible reason it docks the new tab to the right, and to make matters worse, subsequent calls to "Go to Definition" to view additional classes result in the tab of the previously sought out class being closed.

I discovered that these awkwardly placed tabs can be kept open and aligned properly, just like a user would expect, by manually clicking the tiny "keep open" button. But having to do this each and every time I navigate to a class via "Go to Definition" is a real workflow hinderance.

Is there any way to turn off this strange behavior?

Illustration #1: Clicking "Go to Definition" on a highlighted class... enter image description here

Illustration #2: Strange right-aligned tab is the result: enter image description here

Chad Decker
  • 5,997
  • 8
  • 27
  • 31
  • This is due to the new preview/"provisional" tab feature in VS2013. Basically, when you preview a file (either by go-to def/decl, single-clicking a file in the solution explorer, single-clicking a search or find-symbol result, etc.) it opens in a "preview" tab (on the right) that is transient, and replaces whatever previous previewed file was there (so that you don't end up with 100 files open just by browsing through the code a bit). If you want the file to stay opened, you need only to start editing it or click the little star next to the `x` on the tab. – Cameron May 13 '15 at 18:10

2 Answers2

17

In the options, in Environment > Tabs and Windows, uncheck Allow new files to be opened in the preview tab.

enter image description here

isanae
  • 3,253
  • 1
  • 22
  • 47
0

Bizarrely enough this behaviour has just surfaced again in VS 2019 after upgrading from 2017 (which I suspect I'd turned it off in at some point); the solution is still the same.

Steve Mansfield
  • 271
  • 1
  • 3
  • 8