Single layout for 'edit' and 'debug' in Visual Studio

后端 未结 4 517
后悔当初
后悔当初 2021-01-30 20:12

In Visual Studio 2008, \'Start Debugging\' switches Visual Studio to a different layout. How can I force Visual Studio to use a single layout at all times?

I could atte

4条回答
  •  感动是毒
    2021-01-30 20:31

    No, this is not possible. The website you found is indeed accurate:

    There are four different window layout modes in Visual Studio:

    • Design View - this is the one you see when you start up Visual Studio. It's what most people refer to as the "normal" view.
    • Debugging View - this is the view that you get when you enter Debug Mode like when you are stepping through your code
    • Full Screen - the view you get when you go to View -> Full Screen (Shift + Alt + Enter).
    • File View - the lesser known view you can get when you open up a file in DevEnv.eve

    The thing to remember here is that, both, your tool windows and your command bar customizations are saved separately for each state. There is no way to tell Visual Studio to use one state for all modes at this time. Additionally, when you shut down Visual Studio in any state, all four states are saved.

    It's very strange that you would want to use the same window layout for all four modes. The same windows that are useful at design time are hardly ever useful during debugging, and vice versa.
    For example, in Debugging View, I hide the Toolbox, Document Outline, and Property Manager windows. Then, I add the immensely useful Call Stack, Autos, Locals, Processes, Modules, and Breakpoints windows. None of the latter panes would be remotely useful to me in design mode, so I don't want them taking up screen space. But they're invaluable in debug mode, so I want them to show up. I also resize windows in the two different modes, based on their relative importance (such as the Properties window).

    If you really still think that the two views should have the same window layout, the best you can do is rearrange the windows manually to achieve the same layout in both modes. I also recommend exporting your Window Layout settings (Tools -> Import and Export Settings) so that you have a fresh copy to revert back to in the case of disaster. I keep settings files containing my preferred window layout settings for single monitor (laptop), dual monitor, and triple monitor configurations.

提交回复
热议问题