--nextPart2917995.Qe2haVCDtQ Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="iso-8859-1" On Monday 31 October 2011 22:36:08 Peter K=FCmmel wrote: > On 30.10.2011 13:21, Volker Krause wrote: > > Hi! > >=20 > > During the Qt Dev Days in Munich last week we (KDAB) released a new= Free > > Software introspection/debugging tool for Qt applications, called > > GammaRay: > > https://github.com/KDAB/GammaRay > >=20 > > It hooks itself into a Qt application (at start-up or at runtime) u= sing a > > variety of methods (ranging from assembler hacks to (ab)using Qt pl= ug-ins) > > and uses the Qt meta object system for introspecting object, proper= ties, > > signals, slots, signal/slot connections, etc. Nothing really new un= til > > here, tools like Qt Inspector or KSpy can do this already. On top o= f that > > GammaRay adds a bunch of higher level tools though, for example: > >=20 > > - QWidget layout overlay, similar to designer > > - Inspecting a QGraphicsScene and various details of QGraphicsItems= > > (visualizing shapes, bounding rects, transformation origins, etc) > > - Looking at the full (proxy) model hierarchy and all intermediate = results > > in there > > - a live updating QStateMachine visualization > > - attaching of QScriptEngineDebugger and QWebInspector to the > > corresponding > > objects in the application > > - a QTextDocument document object model viewer > >=20 > > Additionally, GammaRay has a plug-in interface for adding new tools= , say a > > KJob tracker. > >=20 > > GammaRay works on Linux, Mac and Windows (MSVC only so far), it nee= ds to > > be > > compiled against the same Qt version used by the application you ar= e about > > to debug though. There's also a Qt Creator plug-in for it > > (https://github.com/KDAB/KDAB-Creator). > >=20 > > Some screenshots can be found here: http://www.kdab.com/gammaray > >=20 > > GammaRay was originally developed in support for the Kontact Touch > > project, > > back when there wasn't a QML debugger yet. The proxy model debugger= also > > proved quite helpful on KMail, maybe it can help some of you as wel= l :) > >=20 > > Needless to say that contributions are very much welcome. > >=20 > > regards > > Volker >=20 > Congratulation for this very nice tool! >=20 > I've also tried to attach to console apps without success. > Then I realized that you use the hijacked process to show > the GammaRay mainwindow which is not possible in a > QCoreApplication executable. >=20 > So I wonder how difficult it would be to run GammaRay in a > different process? Then an IPC mechanism is needed for all > the information. Would this be fast enough? Do you plan > to add this in future? I'd love to have that, for console apps, remote debugging on an embedde= d=20 system, and for less interference with the debugged process :) You can probably get a large amount of the features by having some kind= of=20 network transparent QAbstractItemModel adapter. But some feature need d= irect=20 memory access, like rendering of a second QGraphicsScene view, unless y= ou want=20 to send pixmaps over IPC. > Is there a single point where all the information of > the target process goes through or is it all over the place? > I assume at least each plugin pulls information by itself. Most of it goes through probe.cpp and the object models provided by it,= =20 however all the plug-ins access raw QObject pointers they retrieve from= those=20 models (and thus are bound to the same process). > And how much does the current code depend on x86/64? > Would it be hard to support PPC? There are two injectors that are very architecture specific ("windll" o= n=20 Windows/MSVC and "preload" on Mac), they assume a specific layout in me= mory=20 and rewrite assembly code to intercept function calls. All other injectors should be architecture independent ("preload" on Li= nux,=20 "gdb" on any Unix and "style" everywhere), but I don't think they have = been=20 tested yet on non-x86 either. Probably something I should document in the wiki... regards Volker --nextPart2917995.Qe2haVCDtQ Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part. -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.16 (GNU/Linux) iD8DBQBOr6a1f5bM1k0S0kcRAhq8AJ0Xh9zNY9lwJiyI0TI69/5PQgx6XwCeL7E+ p+MNDkMGLloHsr6bnkffpkk= =vsMH -----END PGP SIGNATURE----- --nextPart2917995.Qe2haVCDtQ--