question: static boolean doesMenuBarBorderToolBar ( JMenuBar c ) { JToolBar tb = ( JToolBar ) MetalToolBarUI . findRegisteredComponentOfType ( c , JToolBar . class ) ; if ( tb != null && tb . getOrientation ( ) == JToolBar . HORIZONTAL ) { JRootPane rp = SwingUtilities . getRootPane ( c ) ; Point point = new Point ( 0 , 0 ) ; point = SwingUtilities . convertPoint ( c , point , rp ) ; int menuX = point . x ; int menuY = point . y ; point . x = point . y = 0 ; point = SwingUtilities . convertPoint ( tb , point , rp ) ; return ( point . x == menuX && menuY + c . getHeight ( ) == point . y && c . getWidth ( ) == tb . getWidth ( ) ) ; } return false ; }
target:  Returns true if the passed in JMenuBar is above a horizontal JToolBar.