how to configure that when selecting a file and press enter in project window, the cursor jump to the editor - clion

I am switching from visual studio to clion and find one thing annoying - when I select a file in a project window and press "enter", the selected file opened in the editor but, unlike in visual studio, the cursor stays in the project window and don't jump to the editor. However, if I use mouse and double-click on the selected file, the cursor jumps to the editor, same as in visual studio. I wonder if there is a way to configure "Enter" in project windows to go to editor as well.

Related

Is there a way to set a keyboard shortcut to open containing folder of a selected file in Solution Explorer in Visual Studio?

When I click on a C++ project in Visual Studio, I get this menu:
And so I can quickly press Alt+F,F(Command ProjectandSolutionContextMenus.Project.OpenFolderinFileExplorer) to open the folder of the project.
I also found that I can open containing folder if I open the file in the Text Editor in Visual Studio:
I bound it to Alt+F,F as well. I set it to only be active in Text Editor, it's the File.OpenContainingFolder command.
But when I click on files inside the project in the Solution Explorer, there is no context menu:
I tried to make the File.OpenContainingFolder command global, but it still doesn't work in the Solution Explorer when I just click on a file once. If I double click it and open it in the text editor, it works.
And I can't find a command in the Keyboard section in options of Visual Studio to open containing folder of a file selected in the Solution Explorer.
Maybe someone knows how to do it?
You can create an external tool menu item, and then bind a shortcut to that item.
Go to Tools > External Tools.
Click Add.
In Title edit box type Show in Explorer.
In Command edit box type explorer.exe.
In Arguments edit box type /select, $(ItemPath). There is a space between a comma and a dollar sign.
Click OK.
Make note at the position of the new command in the list. It could be first, it could be fifth, or something else. Let's assume it's the fifth one.
Assign a shortcut to the command Tools.ExternalCommand5. Restrict the shortcut to Solution Explorer.
That's it.

How do I make Visual Studio 2015 always open files in the main window?

In VS2015, I have my find window in it's own window on my second monitor. When I double click on a file, I want it to open on my main monitor in the main window in a tab next to the rest of my code, but instead it opens in a tab next to the find results.
Anybody know how to change this behaviour?
Undock "Find Window" from Visual Studio Window, and move it to second monitor.
Solution explorer always opens new file docked in side main window.

Shortcut in Visual Studio to open solution in Windows file explorer?

Is there a keyboard shortcut in Visual Studio (currently using 2013) to open the solution (or a project) in the Windows file explorer?
Currently, I normally have to open up the Solution Explorer, right-click on my solution or a project and scroll down to 'Open Folder in File Explorer', but this becomes a time consuming task as I have to do it often (TortoiseGit not integrated with my IDE).
An improvement over #Walt_Ritscher's answer I found was to assign a keyboard shortcut to the File.OpenContainingFolder.
Instead of having to first select a project or solution from the solution project I can simply press a desired keyboard shortcut while any file is in focus (without having to open the Solution Explorer) and it will open the file location in Windows Explorer. This saves time if the focus in my solution explorer is on a file deep in the structure of my solution explorer since I don't have to scroll all the way back up to select a project/solution before hitting the keyboard shortcut.
Yes, you can add your own keyboard shortcut to open the folder.
Open the Tools/Options/Keyboard dialog. In the Show Commands Containing textbox, type OpenFolderIn and you will see the OpenFolderInFileExplorer command. Select the command, then assign a shortcut key. Move your cursor to the Press shortcut keys textbox.then press your desired key combination. In my example I chose Ctrl+Shift+'. Be sure and click the Assign button to memorize the shortcut key
Press OK and you're done.
For visual studio vs2017:
Ctrl+Shift+Alt+O

Shortcut to change which statement is executed next

When debugging in Visual Studio, I can change the line of next execution by dragging the yellow arrow to the desired line.
Is it possible to put the cursor on a line and use a shortcut to do this instead of dragging?
I'm using Visual Studio 2008 at the moment, but this can be done by right-clicking on the source and selecting "Set Next Statement" from the popup menu. I would be surprised if this has been removed from VS2010.
If that's not short enough for you, you can go into "Tools" -> "Customise" and set up a keyboard shortcut to the "Debug.SetNextStatement" command. On my current setup (perhaps not the default), you can press CTRL+SHIFT+F10.

Select code window after compiling

When I am working on a project and compiling all the time, it gets very annoying having to select the code window with the mouse each time after compiling, is there a keyboard shortcut in visual studio to select the code window?
Back when I used Visual Studio, the F4 key went to the next error location in the code and automatically selected the code window. Also try Esc. I think the "next error" keystroke is different in more current versions of VS, so use whatever your keyboard mapping offers.
If you press Alt+W, then Visual Studio opens a list with open windows. You can then select the number corresponding to the window you want to activate. For example, Alt+W,1 activates the first window in the list.

Resources