Debugging

Visual Studio supports debugging Qt C++ applications using the Visual Studio debugger and Qt Quick applications using the QML debug engine. To debug applications on Linux, you can use GDB.

You can debug Qt and Qt Quick applications in Visual Studio by setting breakpoints in C++ and QML files and stepping through the execution of code. While in break mode, you can watch variables and change their values, as well as evaluate arbitrary expressions. For Qt Quick applications, a QML debugging session runs concurrently to a C++ debugging session, which enables you to set breakpoints and watch variables in both C++ and QML during the same debugging session.

To start a debugging session, select Debug > Start Debugging or press F5.

© 2022 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.