Java Tools Tutorials - Herong's Tutorial Examples - v6.23, by Herong Yang
"jaccesswalker" - GUI Component Tree Browser
This section provides a tutorial example on how to use 'jabswitch' and 'jaccesswalker' to display the GUI component tree a Java GUI application on Windows computers.
What Is "jabswitch"? - "jabswitch" is a command line tool that enables or disables the JAB (Java Access Bridge) on a Windows computer. If you want to use "jaccesswalker", "jaccessinspector" or other assistive tool, you must enable the JAB.
What Is "jaccesswalker"? - "jaccesswalker" is a Windows GUI tool that allows you to navigate through the component trees of a Java GUI application.
Here is what I did to run "jaccesswalker" on my Windows computer. Note that I have %java_home%\bin directory included in "path" the environment variable, so that I can run java commands without the path name.
1. Run JInternalFrameListenerTest.java and create 2 internal frames. Keep JInternalFrameListenerTest.java running.
herong> java JInternalFrameListenerTest.java Internal frame opened Internal frame opened Internal frame activated ...
2. Run "jaccesswalker" in a separate window. I see the "jaccesswalker" window displayed.
3. Click "File > Refresh Tree" menu. I see the "JInternalFrameListener Test" GUI component tree listed.
4. Open all branches of the GUI component tree. I see a tree structure like this:
JInternalFrameListener Test [frame] |- [root pane] |- [panel] |- [layered pane] |- [desktop pane] | |- Frame 1 [internal frame] | | |- [root pane] | | |- [panel] | | |- [layered pane] | | |- [panel] | |- Frame 2 [internal frame] | |- [root pane] | |- [panel] | |- [layered pane] | |- [panel] |- [menu bar] |- Frame [menu] |- New [menu item]
Cool. Displaying the GUI component tree dynamically will definitely help troubleshooting any issues in a Java GUI application.
Table of Contents