Class FlatInspector


  • public class FlatInspector
    extends java.lang.Object
    A simple UI inspector that shows information about UI component at mouse location in a tooltip.

    To use it in an application install it with:

     FlatInspector.install( "ctrl shift alt X" );
     
    This can be done e.g. in the main() method and allows enabling (and disabling) the UI inspector for the active window with the given keystroke.

    When the UI inspector is active some additional keys are available:

    • press Esc key to disable UI inspector
    • press Ctrl key to increase inspection level, which shows information about parent of UI component at mouse location
    • press Shift key to decrease inspection level
    • Constructor Summary

      Constructors 
      Constructor Description
      FlatInspector​(javax.swing.JRootPane rootPane)  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addPropertyChangeListener​(java.beans.PropertyChangeListener l)  
      static void install​(java.lang.String activationKeys)
      Installs a key listener into the application that allows enabling and disabling the UI inspector with the given keystroke (e.g.
      boolean isEnabled()  
      void removePropertyChangeListener​(java.beans.PropertyChangeListener l)  
      void setEnabled​(boolean enabled)  
      void update()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • FlatInspector

        public FlatInspector​(javax.swing.JRootPane rootPane)
    • Method Detail

      • install

        public static void install​(java.lang.String activationKeys)
        Installs a key listener into the application that allows enabling and disabling the UI inspector with the given keystroke (e.g. "ctrl shift alt X").
        Parameters:
        activationKeys - a keystroke (e.g. "ctrl shift alt X")
      • addPropertyChangeListener

        public void addPropertyChangeListener​(java.beans.PropertyChangeListener l)
      • removePropertyChangeListener

        public void removePropertyChangeListener​(java.beans.PropertyChangeListener l)
      • isEnabled

        public boolean isEnabled()
      • setEnabled

        public void setEnabled​(boolean enabled)
      • update

        public void update()