VS Code有哪些常用的快捷鍵? Visual Studio Code常用快捷鍵大全

Visual Studio Code是一個運行于 Mac OS X、Windows和 Linux 之上的,針對于編寫現(xiàn)代 Web 和云應(yīng)用的跨平臺源代碼編輯器。深受廣大用戶的喜歡。而,VS Code有哪些常用的快捷鍵?是很多朋友都想知道的問題,今天小編就給大家?guī)砹薞isual Studio Code常用快捷鍵大全,并附有Visual Studio Code官方英文快捷鍵,需要的朋友一起去看看吧!
Visual Studio Code常用快捷鍵大全
按 Press | 功能 Function |
---|---|
Ctrl + Shift + P,F(xiàn)1 | 顯示命令面板 Show Command Palette |
Ctrl + P | 快速打開 Quick Open |
Ctrl + Shift + N | 新窗口/實例 New window/instance |
Ctrl + Shift + W | 關(guān)閉窗口/實例 Close window/instance |
基礎(chǔ)編輯 Basic editing
按 Press | 功能 Function |
---|---|
Ctrl+X | 剪切行(空選定) Cut line (empty selection) |
Ctrl+C | 復(fù)制行(空選定)Copy line (empty selection) |
Alt+ ↑ / ↓ | 向上/向下移動行 Move line up/down |
Shift+Alt + ↓ / ↑ | 向上/向下復(fù)制行 Copy line up/down |
Ctrl+Shift+K | 刪除行 Delete line |
Ctrl+Enter | 在下面插入行 Insert line below |
Ctrl+Shift+Enter | 在上面插入行 Insert line above |
Ctrl+Shift+\ | 跳到匹配的括號 Jump to matching bracket |
Ctrl+] / [ | 縮進/縮進行 Indent/outdent line |
Home | 轉(zhuǎn)到行首 Go to beginning of line |
End | 轉(zhuǎn)到行尾 Go to end of line |
Ctrl+Home | 轉(zhuǎn)到文件開頭 Go to beginning of file |
Ctrl+End | 轉(zhuǎn)到文件末尾 Go to end of file |
Ctrl+↑ / ↓ | 向上/向下滾動行 Scroll line up/down |
Alt+PgUp / PgDown | 向上/向下滾動頁面 Scroll page up/down |
Ctrl+Shift+[ | 折疊(折疊)區(qū)域 Fold (collapse) region |
Ctrl+Shift+] | 展開(未折疊)區(qū)域 Unfold (uncollapse) region |
Ctrl+K Ctrl+[ | 折疊(未折疊)所有子區(qū)域 Fold (collapse) all subregions |
Ctrl+K Ctrl+] | 展開(未折疊)所有子區(qū)域 Unfold (uncollapse) all subregions |
Ctrl+K Ctrl+0 | 折疊(折疊)所有區(qū)域 Fold (collapse) all regions |
Ctrl+K Ctrl+J | 展開(未折疊)所有區(qū)域 Unfold (uncollapse) all regions |
Ctrl+K Ctrl+C | 添加行注釋 Add line comment |
Ctrl+K Ctrl+U | 刪除行注釋 Remove line comment |
Ctrl+/ | 切換行注釋 Toggle line comment |
Shift+Alt+A | 切換塊注釋 Toggle block comment |
Alt+Z | 切換換行 Toggle word wrap |
導(dǎo)航 Navigation
按 Press | 功能 Function |
---|---|
Ctrl + T | 顯示所有符號 Show all Symbols |
Ctrl + G | 轉(zhuǎn)到行... Go to Line... |
Ctrl + P | 轉(zhuǎn)到文件... Go to File... |
Ctrl + Shift + O | 轉(zhuǎn)到符號... Go to Symbol... |
Ctrl + Shift + M | 顯示問題面板 Show Problems panel |
F8 | 轉(zhuǎn)到下一個錯誤或警告 Go to next error or warning |
Shift + F8 | 轉(zhuǎn)到上一個錯誤或警告 Go to previous error or warning |
Ctrl + Shift + Tab | 導(dǎo)航編輯器組歷史記錄 Navigate editor group history |
Alt + ←/→ | 返回/前進 Go back / forward |
Ctrl + M | 切換選項卡移動焦點 Toggle Tab moves focus |
搜索和替換 Search and replace
按 Press | 功能 Function |
---|---|
Ctrl + F | 查找 Find |
Ctrl + H | 替換 Replace |
F3 / Shift + F3 | 查找下一個/上一個 Find next/previous |
Alt + Enter | 選擇查找匹配的所有出現(xiàn) Select all occurences of Find match |
Ctrl + D | 將選擇添加到下一個查找匹配 Add selection to next Find match |
Ctrl + K Ctrl + D | 將最后一個選擇移至下一個查找匹配項 Move last selection to next Find match |
Alt + C / R / W | 切換區(qū)分大小寫/正則表達式/整個詞 Toggle case-sensitive / regex / whole word |
多光標(biāo)和選擇 Multi-cursor and selection
按 Press | 功能 Function |
---|---|
Alt +單擊 | 插入光標(biāo) Insert cursor |
Ctrl + Alt +↑/↓ | 在上/下插入光標(biāo) Insert cursor above / below |
Ctrl + U | 撤消上一個光標(biāo)操作 Undo last cursor operation |
Shift + Alt + I | 在選定的每一行的末尾插入光標(biāo) Insert cursor at end of each line selected |
Ctrl + I | 選擇當(dāng)前行 Select current line |
Ctrl + Shift + L | 選擇當(dāng)前選擇的所有出現(xiàn) Select all occurrences of current selection |
Ctrl + F2 | 選擇當(dāng)前字的所有出現(xiàn) Select all occurrences of current word |
Shift + Alt + → | 展開選擇 Expand selection |
Shift + Alt + ← | 縮小選擇 Shrink selection |
Shift + Alt + (拖動鼠標(biāo)) | 列(框)選擇 Column (box) selection |
Ctrl + Shift + Alt +(箭頭鍵) | 列(框)選擇 Column (box) selection |
Ctrl + Shift + Alt + PgUp / PgDown | 列(框)選擇頁上/下 Column (box) selection page up/down |
豐富的語言編輯 Rich languages editing
按 Press | 功能 Function |
---|---|
Ctrl + 空格 | 觸發(fā)建議 Trigger suggestion |
Ctrl + Shift + Space | 觸發(fā)器參數(shù)提示 Trigger parameter hints |
Tab | Emmet 展開縮寫 Emmet expand abbreviation |
Shift + Alt + F | 格式化文檔 Format document |
Ctrl + K Ctrl + F | 格式選定區(qū)域 Format selection |
F12 | 轉(zhuǎn)到定義 Go to Definition |
Alt + F12 | Peek定義 Peek Definition |
Ctrl + K F12 | 打開定義到邊 Open Definition to the side |
Ctrl + . | 快速解決 Quick Fix |
Shift + F12 | 顯示引用 Show References |
F2 | 重命名符號 Rename Symbol |
Ctrl + Shift + . /, | 替換為下一個/上一個值 Replace with next/previous value |
Ctrl + K Ctrl + X | 修剪尾隨空格 Trim trailing whitespace |
Ctrl + K M | 更改文件語言 Change file language |
編輯器管理 Editor management
按 Press | 功能 Function |
---|---|
Ctrl+F4, Ctrl+W | 關(guān)閉編輯器 Close editor |
Ctrl+K F | 關(guān)閉文件夾 Close folder |
Ctrl+\ | 拆分編輯器 Split editor |
Ctrl+ 1 / 2 / 3 | 聚焦到第1,第2或第3編輯器組 Focus into 1st, 2nd or 3rd editor group |
Ctrl+K Ctrl+ ←/→ | 聚焦到上一個/下一個編輯器組 Focus into previous/next editor group |
Ctrl+Shift+PgUp / PgDown | 向左/向右移動編輯器 Move editor left/right |
Ctrl+K ← / → | 移動活動編輯器組 Move active editor group |
文件管理 File management
按 Press | 功能 Function |
---|---|
Ctrl+N | 新文件 New File |
Ctrl+O | 打開文件... Open File... |
Ctrl+S | 保存 Save |
Ctrl+Shift+S | 另存為... Save As... |
Ctrl+K S | 全部保存 Save All |
Ctrl+F4 | 關(guān)閉 Close |
Ctrl+K Ctrl+W | 關(guān)閉所有 Close All |
Ctrl+Shift+T | 重新打開關(guān)閉的編輯器 Reopen closed editor |
Ctrl+K | 輸入保持打開 Enter Keep Open |
Ctrl+Tab | 打開下一個 Open next |
Ctrl+Shift+Tab | 打開上一個 Open previous |
Ctrl+K P | 復(fù)制活動文件的路徑 Copy path of active file |
Ctrl+K R | 顯示資源管理器中的活動文件 Reveal active file in Explorer |
Ctrl+K O | 顯示新窗口/實例中的活動文件 Show active file in new window/instance |
顯示 Display
按 Press | 功能 Function |
---|---|
F11 | 切換全屏 Toggle full screen |
Shift+Alt+1 | 切換編輯器布局 Toggle editor layout |
Ctrl+ = / - | 放大/縮小 Zoom in/out |
Ctrl+B | 切換側(cè)欄可見性 Toggle Sidebar visibility |
Ctrl+Shift+E | 顯示瀏覽器/切換焦點 Show Explorer / Toggle focus |
Ctrl+Shift+F | 顯示搜索 Show Search |
Ctrl+Shift+G | 顯示Git Show Git |
Ctrl+Shift+D | 顯示調(diào)試 Show Debug |
Ctrl+Shift+X | 顯示擴展 Show Extensions |
Ctrl+Shift+H | 替換文件 Replace in files |
Ctrl+Shift+J | 切換搜索詳細信息 Toggle Search details |
Ctrl+Shift+C | 打開新命令提示符/終端 Open new command prompt/terminal |
Ctrl+Shift+U | 顯示輸出面板 Show Output panel |
Ctrl+Shift+V | 切換Markdown預(yù)覽 Toggle Markdown preview |
Ctrl+K V | 從旁邊打開Markdown預(yù)覽 Open Markdown preview to the side |
調(diào)試 Debug
按 Press | 功能 Function |
---|---|
F9 | 切換斷點 Toggle breakpoint |
F5 | 開始/繼續(xù) Start/Continue |
Shift+F5 | 停止 Stop |
F11 / Shift+F11 | 下一步/上一步 Step into/out |
F10 | 跳過 Step over |
Ctrl+K Ctrl+I | 顯示懸停 Show hover |
集成終端 Integrated terminal
按 Press | 功能 Function |
---|---|
Ctrl+` | 顯示集成終端 Show integrated terminal |
Ctrl+Shift+` | 創(chuàng)建新終端 Create new terminal |
Ctrl+Shift+C | 復(fù)制選定 Copy selection |
Ctrl+Shift+V | 粘貼到活動端子 Paste into active terminal |
Ctrl+↑ / ↓ | 向上/向下滾動 Scroll up/down |
Shift+PgUp / PgDown | 向上/向下滾動頁面 Scroll page up/down |
Ctrl+Home / End | 滾動到頂部/底部 Scroll to top/bottom |
Visual Studio Code官方英文快捷鍵大全
https://code.visualstudio.com/shortcuts/keyboard-shortcuts-windows.pdf
文章結(jié)束,以上就是關(guān)于VS Code有哪些常用的快捷鍵? Visual Studio Code常用快捷鍵大全的全部內(nèi)容,是不是很全面呢?如果你覺得這篇文章還不錯,而且對你有幫助,那就趕快分享給更多的人看到吧!
相關(guān)文章
vscode(Visual Studio Code)配置PHP開發(fā)環(huán)境的方法(已測)
Visual Studio Code一個輕量且強大的代碼編輯器,支持Windows,OS X和Linux。內(nèi)置JavaScript、TypeScript和Node.js支持,而且擁有豐富的插件生態(tài)系統(tǒng),可通過安裝插件來支2018-04-06在vscode中安裝使用pylint-django插件解決pylint的一些不必要的錯誤提
這篇文章主要介紹了在vscode中使用pylint-django插件解決pylint的一些不必要的錯誤提示,需要的朋友可以參考下2018-04-06- Visual Studio Code一個輕量且強大的代碼編輯器,支持Windows,OS X和Linux。內(nèi)置JavaScript、TypeScript和Node.js支持,而且擁有豐富的插件生態(tài)系統(tǒng),可通過安裝插件來支2018-04-05
Visual Studio Code 使用指南(vscode技巧)
VSCode是微軟推出的一款輕量編輯器,采取了和VS相同的UI界面,搭配合適的插件可以優(yōu)化前端開發(fā)的體驗,這里為大家介紹一下vscode的技巧,需要的朋友可以參考下2018-04-05visual studio code教程 vscode的基礎(chǔ)使用和自定義設(shè)置方法
這篇文章主要基于基礎(chǔ)web前端開發(fā),visual studio code教程——基礎(chǔ)使用、擴展插件安裝使用以及少許自定義配置,需要的朋友可以參考下2018-04-04使用vscode 編輯調(diào)試php 配置方與VSCode斷點調(diào)試PHP
以前的php調(diào)試工具,類似zendstudio 或者phpclipse,storm運行太慢了,還是這個好用, 這里就為大家分享一下,需要的朋友可以參考一下2018-04-06