开发者

Qt Creator cannot preview QString when debugging

  • List item
  • Qt-Creator 2.2.0
  • OSX Lion
  • "Use debugger helpers" is checked
  • "Built" and "re-built" all the helpers.

Still... break point on method with QString and the content of the QString cannot be previewed on the debugging pane unless I go to the memory window and search for it manually with the address. I have to use qDebug to dump strings out as if we're in 1983. This use to work and I have no idea what happened to it. Every other type works well.

On Windows 7, the 开发者_运维问答debugger can preview QString objects.


Pastebin the debugger log (right pane of Windows->views->Debugger Log) somewhere and post the link here. And perhaps the log file of the debugger helper rebuilding that you tried?


I had the same problem but after some research I found the answer here: http://silvermace.com/2010/09/qt-creator-debugger-not-displaying-qstring/ I had to chose the correct qmake path and then I had to build the GDB Helper.

As the original site is gone, here are the steps:

  1. sudo rm /usr/local/Qt4.6/qtc-debugging-helper/libgdbmacros.dylib
  2. Start Qt Creator
  3. Qt Creator -> Preferences -> Select the “Qt” tab -> Select “Qt in PATH” under “Auto-detect”
  4. There should be a red cross next to the label “Debugging Helper.” On the right of that there’s a rebuild button – hit it and wait.
  5. The red cross should turn into a green tick.
  6. Clean & Build your project.
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜