@Override
  public @Nullable TextHitInfo getLocationOffset(int x, int y) {
    Point p = new Point(x, y);
    var componentLocation = myMyComponent.getLocationOnScreen();
    p.translate(-componentLocation.x, -componentLocation.y);

    Rectangle[] boxes = ObjectUtils.notNull(myCompositionCharacterBounds, new Rectangle[0]);
    TextHitInfo result = null;
    for (int i = 0; i < boxes.length; i++) {
      Rectangle r = boxes[i];
      if (r.contains(p)) {
        result = TextHitInfo.leading(i);
        break;
      }
    }

    CefLog.Debug("InputMethodRequests::getTextLocation(x: %s, y: %s) -> %s", x, y, result);
    return result;
  }
@Override
  public @Nullable TextHitInfo getLocationOffset(int x, int y)