Is there a way to make Vs-code on Mac only zoom the text/file pane of the window? When I hit Command ⌘+ to zoom, it'll zoom all of the window, ie. also the icons on the left hand side and the file pane on the left as well.
Compare these two screen shots, maybe ;)
Vs-code window, normal
Vs-code window, zoomed in
I'd only like the source file (nfsd.sh in the screen shot) to be zoomed.
Answered in https://stackoverflow.com/a/41684631/5295392:
Out of Box solution for zoom in/out for text only:
Ctrl + Shift + P
Type (Open User Settings)
Search (Edit settings.json)
Add "editor.mouseWheelZoom": true
Save it.
You can use your mouse wheel to zoom in or zoom out only text in the text box.
Open your settings.json file and increase editor.fontSize to increase the size of the text on the source file.
Ctrl + Shift + P
Search 'Zoom'
Pick "Editor Font Zoom In"
Repeat till you get what you want.
On Mac, while pressing the command key, slide two fingers upward to zoom out. Slide downward to zoom in.
Related
In previous versions of VSCode there was an arrow icon at the top of the panel that could be used to maximize the panel, for instance the terminal. I do not know exactly in which version but that button is now gone and I'm unable to find an equivalent.
My question is: how can I maximize the terminal so it takes the whole VSCode window? Is there any way to get the button back?
Which version of VSCode are you using, and in which OS?
On Mac, and with 1.65.2 (the most recent update by now), I have it in the right corner, near the X button:
Shortcuts
Now talking about shortcuts to make your life easier, there are 2 you should be aware of.
PS: Remember that to change any shortcuts, just go over VSCode Command Palette and type Keyboard Shortcuts to change them.
Maximise panel size
There are no default shortcuts for those, in both Windows and Mac.
If you want to set any, the name of the shortcut is View: Toggle Maximized Panel:
Increasing / decreasing terminal size
Now talking shortcuts, if you want to resize your terminal window, in Mac there's a native shortcut that allows to increase / decrease terminal size with Cmd + Ctrl + Arrow Up / Arrow Down.
There's no default for Windows.
If you want to set / change those shortcuts, they are called Terminal: Resize Terminal Down and Terminal: Resize Terminal Up:
Terminal panel on the side
If you added your panel to either left or right, then the mark to make it fullscreen changes.
After clicking on the arrow below, it'll hide all your files and make the terminal to run in the whole screen for VSCode:
I also got the arrow disappeared, but i manage to bring it back by with command:workbench.action.alignPanelCenter
But i don't know i un align it in the first place
So maybe it will work with you
To get the maximize arrow on the left panel...
Left-click the bottom panel, then choose Move Panel Left
To get the maximize arrow on the bottom panel...
First, press the Customize Layout button
And select Center Panel Alignment
Then move the panel back to the bottom.
Panel can be maximized when centered.
Example: If panel is not centered and the Maximize button is missing you also cannot use the command by hitting
Shift-Ctrl-P View: Toggle Maximize Panel
Fix: run these commands (press Shift-Ctrl-P then begin typing)
First command will enable the maximize button
View: Set Panel alignment to Center
Second command will now work to Maximize (or just press the button that shows up now)
View: Toggle Maximize Panel
Blue and skube have the right answer to the original question. I cannot comment so summarize an answer using commands that can be pasted to verify.
In Xcode 10 (and earlier) we could have two editors vertically stacked on top of each other. I have not managed to do that in Xcode 11, only horizontally stacked, which is not optimal using my rotated monitor (using my monitor "in portrait" mode).
Is it possible to vertically align editors?
Choosing File > New > Editor Below will add an editor below the current editor and tell Xcode to vertically stack future editors for that project. You can also choose View > Change Editor Orientation to toggle stacking editors vertically and horizontally.
Thanks to #Mark's answer I knew that it was possible to do vertical alignment of editors, but just now I also discovered that the good old shortcut gets updated according to current Editor aligment.
CMD + SHIFT + O ('Open quickly')
Enter name of type/file you would like to open in a new editor, select the file in the list
Followed by
ALT + ENTER to open the selected file in a new editor (using latest preferred alignemt)
How do I get rid of the minimap in Xcode?
Updated for Xcode 13
Open a code file, such as *.swift, and press the second from the right button in the top right corner. Then click on Minimap:
In older versions of Xcode, this looked as follows:
in XCode 12.0.1
there are 3 ways to hide or show Minimap.
first, you can do it with the Adjust editor option (see the following image).
next way: check or uncheck Minimap from Editor(menu) -> Minimap. (like following image)
and the last way you can use ⌃⇧⌘M and show or hide Minimap.
Navigate to Adjust Editor Options (at the top right corner, to the left of the Add Editor Below button) and uncheck Minimap (or press ^⇧⌘M).
This is called minimap window which give you insight of where you're in part of whole storyboard/code. This feature was introduced in Xcode11 and is quite useful.
You can show/hide simply by using shortcut key as: cmd + shift + ctrl + M.
Alternatively, you can choose 'Adjust Editor Options' i.e multi-lined stacked icon present on top right of Xcode. Deselect Minimap from dropdown list to hide it and Select to show it.
When I scroll with the touch pad with two fingers in Visual Studio Code, I often scroll to the sides a little by accident. This is a bit annoying.
I'd be happy to have it scroll only up and down.
A partially satisfying solution, is to simply press Alt + z, to have the lines wrapped, and then it doesn't scroll to the side.
You can also make wordWrap default as described here How do I turn on text wrapping by default in VS Code
If you have this problem because of Gitlens (blame lines), the solution i found is to disable gitlens.currentLine.scrollable (or set it to false in the settings json file.
Pressing alt + z to disable horizontal scrolling, works fine for a current single file. If you want permanent solution then for every file you visit? then follow:
Settings > Text Editor > Diff Editor > Word Wrap to on
Note: in case you don't know where is this Settings, just go
1. Via MENU
File > Preferences > Settings > Text Editor > Diff Editor > Word Wrap
2. Via shortcut Keys
On Windows
ctrl + , (control + comma)
On Mac - correct me if I am wrong
command + , (command + comma)
Just want to add that some plugins, like GitLens, may mess this setting up.
E.g., with GitLens, it can add git blame information inline, at the end of each line of code, showing you who is responsible for that line's current version, and when.
Unfortunately, this information will not only be to the right of the wrap column, e.g. 80, it'll also "unlock" the horizontal scrolling, even when no GitLens blame annotation is there.
I haven't found any fix for this other than disabling such features.
Just press ALT + Z -> To enable/disable the horizontal scroll
Config: MBP 2018 | Using Magic Mouse 2.
For me, I had accidentally set the 'Scroll Beyond Last Column' to 80 chars. Just resetting it to default settings is what worked for me. Hope it does for you all!
Update (6th Feb, 2021): Enabling the mini-map again causes the problem. So disabled it to get rid of the issue.
⌥ + z
the shortcut for Mac. you welcome
February 2020 (version 1.43) update adds an option called: Scroll Predominant Axis
Scrolling predominant axis
When trying to scroll vertically using a modern touchpad, it oftentimes happens that the file scrolls horizontally as well. There is now a new setting, editor.scrollPredominantAxis (which is set to true by default) which blocks "diagonal" scrolling. This forces scrolling gestures to be either vertical or horizontal (based on the highest absolute scroll delta), but never diagonal.
When enabled,it prevents any diagonal scrolling.
It guesses your scrolling to either vertical scroll or horizontal scroll.
It says by default it is enabled. If not then you can enable in Scroll Predominant Axis in settings.
Screenshot: Editor: Scroll Predominant Axis
Or in settings.json
"editor.scrollPredominantAxis": true
Use Ctrl + E, then Ctrl + W for disable horizontal scrolling.
For more details, you can refer this cite: https://developercommunity.visualstudio.com/t/disable-horizontal-scrolling-in-visual-studio-2019/612873.
Is there a keyboard shortcut to quickly hide the left/right panels in RStudio? I can drag the vertical bar to resize the panels but that's cumbersome.
I'm not sure that there's a hotkey for hiding the left / right / upper / lower panels, but you might find the shortcut keys for zooming to a given quadrant pane useful.
For example, in Linux (and I'm guessing Windows):
CTRL+SHIFT+1 = Zoom Source
CTRL+SHIFT+2 = Zoom Console
...
CTRL+SHIFT+0 = Show All Panes
The whole list of the pane zoom shortcut keys can be seen under the View > Panes menu. These hotkeys seem to be rather recent additions, as the earliest mention that I can see of them is for release v0.99.902.