Vscode顯示多個文件
按ctrl+shift+P,在搜索框中輸入:setting.json,打開文件,輸入如下內容:
{ "workbench.editor.showTabs": true, "workbench.editor.enablePreview": false, }
VSCode打開多個文件時實現標簽欄多行顯示
默認情況下,VSCode的標簽欄是滾動式的,當打開多個文件時是在同一行中顯示的,想要選擇查看某個文件時很不方便。
如果想要實現多行顯示標簽頁,也是可以的,具體方法如下。
操作步驟:
1. 安裝Custom CSS and JS Loader插件
2. 添加文件/Users/txy/.vscode/tabs-wrapper.css
.title { height: auto !important; } .tabs-and-actions-container { display: block !important; height: auto !important; } .tabs-and-actions-container .monaco-scrollable-element { height: auto !important; } .tabs-container { overflow: initial !important; height: auto !important; display: flex !important; flex-wrap: wrap !important; } .tabs-and-actions-container .editor-actions { position: fixed !important; right: 0 !important; z-index: 20 !important; bottom: 20px !important; background: #222 !important; }
3. 在settings.json中添加:
"vscode_custom_css.imports": [
"file:///Users/zmj/.vscode/tabs-wrapper.css"
],
"vscode_custom_css.policy": true,
4. 按cmd+shift+p呼出命令框,輸入命令Reload Custom CSS and JS
5. 重啟vscode即可,效果如下圖所示
轉載:https://blog.csdn.net/tangyang8941/article/details/107169763