the blog
Back to -Blog

Amethyst Flex Debugger

A First Look
by Dermot Hogan
Thursday 5 February 2009.

The Visual Studio is the best IDE debugger available: in my mind there is no doubt on that matter. Well, I’ve now got the Visual Studio debugger working in Amethyst. Getting a debugger of any sort to work with Visual Studio isn’t easy. Getting the finer points operational (such as conditional breakpoints, trace points and so on) can be very tricky.

In fact, getting the Amethyst Flex debugger operational turned out to be quite a bit easier than I was anticipating, mainly because I’d written one before – for Ruby. While Ruby and Flex are completely different animals programmatically speaking, from the Visual Studio debugger view, they look surprisingly similar.

Briefly, the main features of the Amethyst/Flex debugger are:

- ability to set and remove breakpoints
- examine the call stack (the Call Stack Window)
- examine local variables (the Locals Window)
- examine and modify individual variables (the Watch Window)

In addition, we’ve added a ‘console’ where the Flex tracing information is displayed (this comes from the ActionScript ‘trace’ call).

First off, here’s a picture of the Breakpoints Window showing some breakpoints - some are ’enabled’ meaning that they will fire; and some ’disabled’ - they will be skipped over. Under that, there’s the Call Stack Window and under that, the Amethyst Console Window where the trace information from the ActionScript application is written to. Finally, there’s a Watch Window showing the value of a variable in hexadecimal.

Here’s an example of an object literal (a bit messy, but it shows the drill down nicely):

And this is what it looks like in the Watch Window:

And of course we have ’hover’ tips. Here, I’ve put the mouse over the variable ’a’ which is an Array:

Lastly, here’s ’this’ (a very good test!):

All of these and more (conditional breakpoints, breakpoints being activated after a number of hits, tracepoints, etc.) will be available in our next beta of Amethyst, available in a week or two.

Bookmark and Share   Keywords:  Amethyst  debugger
© SapphireSteel Software 2014