vscode 配置构建、调试QT项目

  1. 背景是已经安装好了QT和QT相关的所有依赖包 https://mp.csdn.net/mp_blog/creation/editor/142974086

  2. 配置环境变量

找不到或者忘记在哪里可以使用指令查询

3.插件安装Qt Support、 Qt tools、Qt UI等

Cmake、Cmake Tools 等

C/C++等

settings.json 配置

此部分是根据一些报错进行配置更新的

vscode:插件报错:_unable to determine what cmake generator to use. p-CSDN博客

javascript 复制代码
{
  "workbench.colorTheme": "Default Dark Modern",
  "git.autofetch": true,
  "settingsSync.ignoredSettings": [],
  "editor.tabSize": 2,
  "eslint.format.enable": true,
  "javascript.updateImportsOnFileMove.enabled": "always",
  "liveServer.settings.donotShowInfoMsg": true,
  "javascript.format.enable": false,
  "js/ts.implicitProjectConfig.target": "ESNext",
  "editor.codeActionsOnSave": {},
  "editor.detectIndentation": false,
  "[vue]": {
    "editor.defaultFormatter": "esbenp.prettier-vscode"
  },
  "[typescript]": {
    "editor.defaultFormatter": "esbenp.prettier-vscode"
  },
  "[dart]": {
    "editor.formatOnSave": false,
    "editor.formatOnType": true,
    "editor.rulers": [80],
    "editor.selectionHighlight": false,
    "editor.suggestSelection": "first",
    "editor.tabCompletion": "onlySnippets",
    "editor.wordBasedSuggestions": "off"
  },
  "editor.fontLigatures": false,
  "window.zoomLevel": 2,
  "cssrem.rootFontSize": 37.5,
  "git.confirmSync": false,
  "cmake.generator": "MinGW Makefiles",
  "cmake.pinnedCommands": [
    "workbench.action.tasks.configureTaskRunner",
    "workbench.action.tasks.runTask"
  ],
  "cmake.options.statusBarVisibility": "visible",
  "cmake.cmakePath": "C:\\Users\\Administrator\\Desktop\\qtServer\\Tools\\CMake_64\\bin\\cmake.exe",
  "qt-support.qtInstallDirectories": [],
  "cmake.additionalKits": [
    "C:\\Users\\Administrator\\AppData\\Local\\qt-support\\qt-kits.json"
  ],
  "C_Cpp.intelliSenseEngine": "disabled"
}

点击下图左下角,选择Qt 6.7.3....

开启构建,成功构建 ,几个调试、构建操作

相关推荐
_r0bin_3 小时前
前端面试准备-7
开发语言·前端·javascript·fetch·跨域·class
zhang98800003 小时前
JavaScript 核心原理深度解析-不停留于表面的VUE等的使用!
开发语言·javascript·vue.js
Fanxt_Ja5 小时前
【JVM】三色标记法原理
java·开发语言·jvm·算法
蓝婷儿5 小时前
6个月Python学习计划 Day 15 - 函数式编程、高阶函数、生成器/迭代器
开发语言·python·学习
love530love5 小时前
【笔记】在 MSYS2(MINGW64)中正确安装 Rust
运维·开发语言·人工智能·windows·笔记·python·rust
slandarer6 小时前
MATLAB | 绘图复刻(十九)| 轻松拿捏 Nature Communications 绘图
开发语言·matlab
狐凄6 小时前
Python实例题:Python计算二元二次方程组
开发语言·python
roman_日积跬步-终至千里6 小时前
【Go语言基础【3】】变量、常量、值类型与引用类型
开发语言·算法·golang
roman_日积跬步-终至千里6 小时前
【Go语言基础】基本语法
开发语言·golang·xcode
Felven6 小时前
C. Basketball Exercise
c语言·开发语言