private Component getFirstAvailableComponentThatHasHelp(Component component) {
		HelpService helpService = DockingWindowManager.getHelpService();
		HelpLocation helpLocation = helpService.getHelpLocation(component);
		if (helpLocation != null) {
			return component;
		}

		Container parent = component.getParent();
		if (parent == null) {
			// nothing else to check
			return null;
		}

		return getFirstAvailableComponentThatHasHelp(parent);
	}
A base system action used for actions that show help information.
Ghidra/Framework/Docking/src/main/java/docking/action/AbstractHelpAction.java