Debugging BlackBerry User Interface Code

The most effective debugging techniques are usually the simplest; printf(), echo(), System.out.println().

If you’re debugging UI code for the BlackBerry, here’s your printf() :

protected void paint ( Graphics graphics )
{
    graphics.setColor ( 0x00FFFFFF );
    graphics.drawRect ( 0, 0, getWidth(), getHeight() );
    super.paint ( graphics );
}