How to stop visual studio from auto expanding code regions? - visual-studio

As the title describes, how I could stop visual studio from auto-expand code region? I'm using visual studio on a C++ project.
For example, sometimes when I delete some part of my code it unfolds a lot of regions far away up from where the line was deleted.
This behavior also happens sometimes when I'm scrolling, from nothing it expands the region.
I saw there's an option on edit > outlining > stop outlining
But this disables all kind of code folding, I just want to stop visual studio herself from auto-expanding any kind of code.
This is frustrating, it happens a lot of times and I need to stop what I'm doing to fold everything again.

Related

Always Show Snippets on Top in Visual Studio

I have some snippets that work nicely, but the suggestion in the info box only shows up in 'simple' context (e.g. beginning of the line, etc.), rarely when I'm nested (e.g. as function parameters). However, when I do press on "Show more results (Ctrl+J)", it does show up (and works, of course).
How do I get my snippets to always show and always show on top? Ironically, this is easily done in Visual Studio Code ("editor.snippetSuggestions": "top"), but I can't get it to work in Visual Studio 2022.
Thank you in advance!

How to save a code in which I set up hide selection in visual studio?

I am using visual studio 2013 with Fortran. My code is so long, so I use hide selection very often. However, when I turned off the visual studio and restart the program, hide selections I set up before disappear. This happens only to the main code that is the longest. Other subroutines keep hide selections I used. Do you have any good idea to solve this?

Visual Studio's Ctrl+tab messing up and disappearing

So I've seen a couple of questions about Visual Studio's Ctrl+Tab but none of them were referring to my problem
My Visual Studio will randomly start acting funny. Sometimes, when I hit on Ctrl+Tab to change tab, the navigation pane appears for half a second an disappears. If I hold Ctrl+Tab, it'll just appear and disappear constantly, disappearing too early to even switch one tab. When it disappears it gives the keyboard focus back to whichever document I was on (so no other program actually intercepts the focus)
Then it will randomly accept my Ctrl+Tab and stay on screen once every X tries for some reason.
I double-checked my Visual Studio parameters (which have never changed) and the shortcuts are correctly set: Ctrl+Tab to Window.NextDocumentWindowNav and Ctrl+Shift+Tab to Window.PreviousDocumentWindowNav. I try removing them and resetting them with no success.
Anyone ever had this problem? I don't know what is intercepting my Ctrl+Ctrl+Tab. When I restart Visual Studio, it'll work fine again for a while until at some point Ctrl+Tab messes up again for no reason.
Anyone ever had this bug? Any tips on how to figure out what it's from and how to fix it? I'm on Visual Studio 2013. If it's any help, I also have Resharper 8.2.1 with it
Thanks!
EDIT
A few extra details:
Disabling Resharper doesn't remove the problem, still happens
I tried setting the NextDocumentPaneNav shortcut to another combination, bug still happened
So basically it's not another running program catching Ctrl+tab for some reason, it's literally Visual Studio not willing to show the navigation pane for more than a micro second

Foce visual studio to break in the running

I have an application(not mine) that just seems to hang. I would like to see what it's trying to process, or if it's processing anything. Is that a button in visual studio that I can click that will break at the point it's trying to process?
If you click on the left side of the editor (the place where you actually edit the text), then you will set a breakpoint on that line. When debugging, if your program reaches that line of code, then Visual Studio will stop running your program and let you debug it.
So just set a breakpoint immediately before where you think the problem is.

Visual Studio 2012 Keyboard Freezing

I am having an issue within the razor view in Visual Studio 2012. For some reason, most of the time when I am trying to edit a style property, my keyboard freezes and doesn't allow me to type anything.
<section style="height: 15[Try to edit here]">
For instance, trying to add in a zero or 'px' where the "Try to edit here" has been placed above is impossible as the keyboard freezes.
I have ReSharper 7.1 installed, I'm not sure if that is the culprit?
Closing the tab and re-opening it fixes the issue, but it then re-occurs later on (not sure if there is a pattern as to when it re-occurs)
This happens to me often. I just switch tabs and come back and it doesn't happen(for sometime of course :-)). It could be some kind of unresolvable bug although i would suggest that you uninstall ReSharper and try again to see if it gets fixed.
It happens to me and my other colleagues as well.
I have found it to be linked to having a floating code window(s). Unlike the floating window for something like Find Results (without a title bar), these appear almost like another instance of Visual Studio. These do not come to the front when the main Visual Studio Window is selected. I have found the keyboard stops responding only on these windows if there is a Find Results kind of floating window open. When the problem occurs, clicking on another VS window and come back sorts it.
In earlier versions of VS, any pulled code windows appeared without a thick title bar and window controls box.
I tried posting images of the two kinds of floating windows but don't have enough reputation to do so! Let me know if it is confusing and I'll try to clarify.
This may not be the only way for this problem to occur but this is what I've observed consistently in the last few weeks of using Visual Studio 2012. I have C# environment settings with Resharper 7 and Reflector installed.

Resources