Title: JTree Expansion based on KeyPress

Hello Swing Experts,
        I have a need to expand the JTree based on the key press(es) (up to 3 chars).  This feature is similar to Windows File Explorer.  In the Windows File Explorer, on the left hand side (where you have the directory tree structure), if you press any key, the tree selection will be moved to a dir starting with that letter (of key pressed) and immediately if you press another key, the selection will be for the second letter.  For example, consider the directory structure below:

                T
                Te
                Tes
                Test
The first time, when you press "T", the dir with the name "T" is selected and immediately if you press "e", the selection is changed to "Te" and if you press "s" immediately, the selection is changed to "Tes".  How can I do this in Java?

Thanks

Sai

Reply via email to