Welcome to the world of vscode. The goal of this article is to popularize some design concepts about [space control] in vscode. Space is limited, but information is unlimited, just like us When writing a page, you must consider the center of the page and the placement of the space. vscode is actually an application, and its interface space is also limited. These are built up by various areas. So what are these areas? How do they work together? [Recommended learning: "vscode tutorial"]
The main content of this article can be said to be tips, but I am a very lazy person, I don’t like to memorize by rote, I like to remember when I need to Looking for internal connections between the contents, and then using logic to string them together, this gives me an indescribable pleasure; this memory method may not be suitable for many industries, but in the computer field, it is really a method that I personally highly recommend. The reason is simple: computers are a world built entirely by humans!
This means that if you can understand the designer's thinking, the design of many things will become logical, and it would feel awkward not to use it this way. Another potential benefit is that we come to think like those good people, which is crucial.
I’ve talked a lot, let’s get down to business, let’s get started!
vscode Area Overview
Taking the above picture as an example, our common and commonly used areas and corresponding functions It is roughly as follows
Working directory: Directory information of the currently processed project
Command panel: Provides a panel that supports calling vscode corresponding actions through commands
Editing area: an area to change the content of the current project, there are concepts such as editing groups
-
Terminal area: Provide a way to embed the terminal area in vscode Directly execute terminal commands in win, default
power shell
; can be configured as bashKnowing the existence of these core areas, next, we start to analyze one by one
Edit area
The editor area is the most critical area, because it is the entrance to our direct control of the project, normal file operation design The concept is actually mainly about the operation of the cursor. This has been shared in the article Cursor Operation, so I won’t go into details. Interested friends can take a look;
The focus of this article is Regarding the allocation of space, the editing area is the area that is displayed by default and occupies the largest area. For the processing of this space, the main requirements are as follows
- How to switch between multiple open files
- How to see the corresponding content of multiple files at the same time
For the first question, it can be achieved through a type of shortcut keys; for the second question, the concept of editor group is proposed in vscode. The editing area can be divided into up to five areas, which are independent of each other.
If you have read the article Cursor Operation, you will know that I use the [granularity] perspective to understand the cursor setting. In fact, spatial control can also be understood from this perspective. How to understand it specifically? Do, let’s understand through the questions
How to switch between multiple open files in the editing area: shortcut keys
Let’s take a look first Default shortcut key settings
Command | mac | win | ||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Select in the currently open file list | ctrl tab | ctrl tab | ||||||||||||||||||||||
Switch to the next in the current file | Open Previous Editor | cmd option ← | ctrl option ← | ||||||||||||||||||||||
cmd option → | ctrl option → |
Command | mac | win |
---|---|---|
Select | ctrl in the list of currently open files tab | ctrl tab |
Switch to the next in the current file | Open Previous Editor | cmd option ← (customized ctrl option ← ) | |
Switch to the previous one in the current file | Open Next Editor | cmd option → (customized ctrl option → ) |
How to see the corresponding content of multiple files in the editing area at the same time: Editor Group
For such a large piece of content in the editor area, if you want to see multiple processed files at the same time, then split it. This leads to the concept of Editor Group. In fact, It is divided into partitions, and the functions are exactly the same. Just look at the case directly
Regarding the grasp of the editor group space, in the same sentence, The editor group granularity is cmd
, the corresponding command overview is as follows;
Command Overview
Command | mac | win |
---|---|---|
Split Editor | Split Editor | Cmd \ | Ctrl \ |
Split switch | Switch the current editor in the editor group | Cmd [number of groups] | Ctrl [number of groups] |
Flip Editor Group Layout | Switch vertical/horizontal editor layout | Cmd Option 0 | Shift Alt 0 |
Switch
Command | mac | win |
---|---|---|
Split switch | Switch the current editor in the editor group | Cmd [number of groups] | Ctrl [number of groups] |
Switch editor group direction
The default editor arrangement between editor groups is horizontal
Command | mac | win | ||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Cmd Option 0 | Shift Alt 0 |
mac | win | |
---|---|---|
cmd ctrl ← | ctrl tab | |
cmd ctrl ← |
mac | win | |
---|---|---|
ctrl tab | ctrl tab | in the currently open file list |
cmd option ← (customized ctrl option ←) |
|
|
cmd option → (customized ctrl option → ) |
|
mac | win | |
---|---|---|
ctrl tab | Move Editor into Next Group | Move the current file to the next editor | |
##Command Panel Area
The command panel is actually an input box, using a strategy mode, and behaviors are classified according to the prefix identifier. vscode sets the concept of symbols, which means collections of variables, functions, calls, etc.
In fact, they can be roughly divided into two categories, special logos and special characters. This distinction will make it easier to remember.Special identification
Shortcut key for Mac | Shortcut keys for win | ||
---|---|---|---|
cmd p |
? |
||
Execute command |
|||
##[ filename?]:[rowIndex] | Locate the line number (if you don’t specify a file name, it will be the currently opened file)|||
ctrl g | @[:?] | Fuzzy query for current file symbols, if not filled in, all will be displayed by default (if added: will be displayed in categories) | |
Ctrl Shift O | # Fuzzy query for symbols in the currently open file list, if not filled in, the default is empty | ||
Special characters | Source word
##edt [active?] | edit | ||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
ext [install?] | extension For help on possible operations, add | install||||||||||||||||||||||||
task Perform the task |
||||||||||||||||||||||||
debug | Execute debugging | |||||||||||||||||||||||
term | terminal | Create and manage terminal instances | |||||||||||||||||||||||
view | Open Various UI components of VS Code | |||||||||||||||||||||||
Extended FeedBased on the command panel, there is actually a set of sorting out the search function in vscode. Due to space limitations, it will be described in a short article (tool article) in the next article ) appears in the form Terminal areais easier to understand, but it is actually some commands
Sidebar area The sidebar only cares about one very commonly used key shortcut key, which is to show/hide the sidebar
At this point, we have completed the vscode journey with space control as the main line! Be diligent in thinking, enjoy thinking, come onFor more knowledge about VSCode, please visit:vscode Basic Tutorial |
The above is the detailed content of Take you to understand [Space Control] in vscode. For more information, please follow other related articles on the PHP Chinese website!

2022年了,该学会用VSCode debug了!下面本篇文章手把手带大家会习VSCode debug,希望对大家有所帮助!

本篇是VSCode配置文章,手把手教大家怎么在VSCode中配置使用 Geant4 和 Root,希望对大家有所帮助!

本篇文章扒拉一下vscode Prettier的选项,总结分享16个让你的代码变漂亮的属性,希望对大家有所帮助!

“工欲善其事,必先利其器!”,vscode作为前端开发的重要工具,其插件能大幅提升战斗力,精心收集12个插件,总有几款你还未曾拥有。

VSCode中如何开发uni-app?下面本篇文章给大家分享一下VSCode中开发uni-app的教程,这可能是最好、最详细的教程了。快来看看!

VScode中怎么开发置C/C++?怎么配置C/C++环境?下面本篇文章给大家分享一下Windows系统下VScode配置C/C++环境图文教程,希望对大家有所帮助!


Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

mPDF
mPDF is a PHP library that can generate PDF files from UTF-8 encoded HTML. The original author, Ian Back, wrote mPDF to output PDF files "on the fly" from his website and handle different languages. It is slower than original scripts like HTML2FPDF and produces larger files when using Unicode fonts, but supports CSS styles etc. and has a lot of enhancements. Supports almost all languages, including RTL (Arabic and Hebrew) and CJK (Chinese, Japanese and Korean). Supports nested block-level elements (such as P, DIV),

SublimeText3 Linux new version
SublimeText3 Linux latest version

Notepad++7.3.1
Easy-to-use and free code editor

PhpStorm Mac version
The latest (2018.2.1) professional PHP integrated development tool

Dreamweaver CS6
Visual web development tools
