[Interest] Debugging in Qt Creator and displaying Qt objects d_ptr members in watch window ?

Edward Sutton edward.sutton at subsite.com
Thu Sep 17 18:49:58 CEST 2015



On Sep 17, 2015, at 11:27 AM, Thiago Macieira <thiago.macieira at intel.com<mailto:thiago.macieira at intel.com>> wrote:

*External Message - use caution*


On Thursday 17 September 2015 13:45:40 Edward Sutton wrote:
spend too much time adding qDebug() statements because Qt objects d_ptr
members are invisible to the debugger.

You can disable the pretty printers by right-clicking the area and unchecking
the mark. You can also add an expression to be evaluated consisting of
yourobjectname->d_ptr, which you can then expand.

Thanks for the tips!



I collected tips on my wiki and pasted below for others:

Qt Debugging Setup
Qt Creator is not Visual Studio but for a cross-platform IDE and debugger it is tolerable.
Tips:

  *   Use the Qt Visual Studio Add-in for Qt5 for Windows development
     *   Offers a seamless integration of Qt development tools for Microsoft Visual Studio.
     *   qt-vs-addin-enterprise-1.2.4.exe
  *   You can disable the pretty printers by right-clicking the area and unchecking the mark.
  *   You can also add an expression to be evaluated consisting of yourobjectname->d_ptr, which you can then expand.
  *   Be sure that you have gone into the Projects tab in Qt Creator,
     *   Select the Run half of the button for the kit you're using
     *   Turn on the checkbox "Use debug version of frameworks"

Windows
Install the command line debugger cdb.exe included with the Windows SDK:
Windows SDK for Windows 8.1

sdksetup.exe


  1.  Install the Windows Software Development Kit (SDK) for Windows 8.1

C:\Program Files (x86)\Windows Kits\8.1\
C:\Program Files (x86)\Windows Kits\8.0\Debuggers\x86\cdb.exe
C:\Program Files\Windows Kits\8.0\Debuggers\x64\cdb.exe


Select the features you want to install:

  *   [x] Windows Software Development Kit
  *   [x] Windows Performance Toolkit
  *   [x] Debugging Tools for Windows
  *   [x] Application Verifier for Windows
  *   [x] .NET Framework 4.5.1 SDK
  *   [x] Windows App Cert Kit
  *   [x] MSI Tools

Qt Plug-In for VS 2013[edit<http://subsitedesign/wiki/index.php?title=Qt&action=edit&section=10>]

  *   Filename: qt-vs-addin-enterprise-1.2.4.exe

Description: Qt Visual Studio Add-in for Qt5 offers a seamless integration of Qt development tools for Microsoft Visual Studio. The Qt Visual Studio Add-in allows developers to use this standard development environment without having to worry about any Qt-related build steps or tools.
Note: The Qt Visual Studio Add-in will not work on Visual Studio Express editions.



--
Thiago Macieira - thiago.macieira (AT) intel.com<http://intel.com>
 Software Architect - Intel Open Source Technology Center

_______________________________________________
Interest mailing list
Interest at qt-project.org<mailto:Interest at qt-project.org>
http://lists.qt-project.org/mailman/listinfo/interest

This email and any files transmitted with it from The Charles Machine Works, Inc. are confidential and intended solely for the use of the individual or entity to which they are addressed. If you have received this email in error please notify the sender. Our company accepts no liability for the contents of this email, or for the consequences of any actions taken on the basis of the information provided, unless that information is subsequently confirmed in writing. Please note that any views or opinions presented in this email are solely those of the author and do not necessarily represent those of the company. Finally, the recipient should check this email and any attachments for the presence of viruses. The company accepts no liability for any damage caused by any virus transmitted by this email.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20150917/7f2e613b/attachment.html>


More information about the Interest mailing list