如何在Visual Studio Code中使用Qt? [英] How use Qt in Visual Studio Code?

查看:137
本文介绍了如何在Visual Studio Code中使用Qt?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在Visual Stuidio Code操作系统Linux Mint 18中使用Qt?

How do I use Qt in Visual Stuidio Code operating system Linux Mint 18?

Marketplace不存在Qt的扩展名.也许有人知道更多!

Marketplace doesnt exist extension for Qt. Maybe anyone knows more!

UPD.我的意思是通过键入Qt AddIn

UPD. I meant that by type Qt AddIn

推荐答案

您应该为此扩展提供机会:

You should give a chance for this extension: https://marketplace.visualstudio.com/items?itemName=ms-vscode.cpptools

以此,您可以配置包含路径以获得更好的IntelliSense结果.

With this, you can configure include paths for better IntelliSense results.

配置includePath

一种配置QtCore模块的方法.

One way to configure e.g the QtCore module.

  1. Ctrl + Shift + p 打开命令面板
  2. 搜索:C/Cpp:编辑配置
  3. 您应该有一个新标签,名为: c_cpp_properties.json
  4. configuration 数组中,您应编辑 Linux 部分
  5. includePath 设置中添加路径,例如:/usr/include/x86_64-linux-gnu/qt5/QtCore
  1. Ctrl + Shift + p to open command palette
  2. Search for: C/Cpp: Edit Configurations
  3. You should have a new tab called: c_cpp_properties.json
  4. In configurations array you should edit the Linux section
  5. Add your paths in the includePath setting e.g: /usr/include/x86_64-linux-gnu/qt5/QtCore

有关更多信息,请检查以下内容: https://github.com/Microsoft/vscode-cpptools/blob/master/Documentation/Geting%20started.md

For more check this: https://github.com/Microsoft/vscode-cpptools/blob/master/Documentation/Getting%20started.md

IntelliSense引擎

我们建议使用默认"引擎以获得最佳的IntelliSense体验.但是,可以通过编辑用户或工作空间设置来明确选择IntelliSense引擎.您应该修改的设置是 C_Cpp.intelliSenseEngine

We recommend using the "Default" engine for the best IntelliSense experience. However, it is possible to explicitly choose the IntelliSense engine by editing your user or workspace settings. The setting you should modify is C_Cpp.intelliSenseEngine

  • Default - Visual Studio 的 IntelliSense 引擎,它是提供语义感知 IntelliSense 功能的默认引擎
  • Tag Parser -提供快速但模糊"结果的模糊" IntelliSense引擎,如果默认引擎为
  • ,则可用于提供后备体验
  • Default - Visual Studio's IntelliSense engine, which is the default engine that provides semantic-aware IntelliSense features
  • Tag Parser - the "fuzzy" IntelliSense engine that provides quick but "fuzzy" results, is used to provide the fallback experience if the default engine is

有关它的更多详细信息: https://github.com/Microsoft/vscode-cpptools/blob/master/Documentation/LanguageServer/IntelliSense%20engine.md

More details about it: https://github.com/Microsoft/vscode-cpptools/blob/master/Documentation/LanguageServer/IntelliSense%20engine.md

这篇关于如何在Visual Studio Code中使用Qt?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆