[Qt-creator] Debugger display for array data

May, Ryan ryan.may at eecradar.com
Fri Nov 16 02:13:09 CET 2012

On Nov 15, 2012, at 17:57, "André Pönitz" <andre.poenitz at mathematik.tu-chemnitz.de> wrote:

> On Thu, Nov 15, 2012 at 05:27:49PM +0000, May, Ryan wrote:
>> I can dump the memory to a file using GDB and plot using Python, but it'd
>> be much quicker to keep this within Creator.
>> Thoughts?
> Starting point are share/qtcreator/dumper/qttypes.py and
> http://qt-project.org/doc/qtcreator-2.6/creator-debugging-helpers.html
> Essentially you have to make up your mind how you want the result
> to be presented, i.e. "in place" in the Locals and Expressions view,
> or in a separate window (or be able to toggle between both), then 
> maybe look at the implementation of the dumpers for types that are
> similar to yours. 
> There is currently no "in place" display for anything truly two dimensional,
> but there are several "generic" ways to show data in separate windows,
> strings in textedits, images, and processes.


This is pretty much where my thoughts had gone; thanks for the reference and the concrete example (I've played with simpler dumpers before).  My big stumbling block right now is: how can I get this dumper to run for data not in a class, but for a local function variable like:

unsigned char data[240][240];

It's old code from C, so I don't have the luxury of a proper data structure. I can't find any way to get this dumped as a whole rather than as a tree of char.


More information about the Qt-creator mailing list