private void showHint() {
    if (!myComponent.isShowing() || !IJSwingUtilities.hasFocus(myComponent)) {
      hideHint();
      return;
    }

    // 1. Hide previous hint (if any)
    hideHint();

    // 2. Found error (if any)
    List<ErrorInfo> infos = getErrorInfos();
    if (!ErrorInfo.haveFixes(infos)) {
      hideHint();
      return;
    }

    boolean error = false;
    for (ErrorInfo errorInfo : infos) {
      if (errorInfo.getLevel() == HighlightDisplayLevel.ERROR) {
        error = true;
        break;
      }
    }

    // 3. Determine position where this hint should be shown
    Rectangle bounds = getErrorBounds();
    if (bounds == null) {
      return;
    }

    // 4. Show light bulb to fix this error
    myHint = new LightweightHint(new InspectionHint(error ? AllIcons.Actions.QuickfixBulb : AllIcons.Actions.IntentionBulb));
    myLastHintBounds = bounds;
    myHint.show(myComponent, bounds.x - AllIcons.Actions.IntentionBulb.getIconWidth() - 4, bounds.y, myComponent, new HintHint(myComponent, bounds.getLocation()));
  }
private void showHint()