@ApiStatus.Internal
  public void fitToScreen(Rectangle rect) {
    Rectangle before = null;
    if (LOG.isDebugEnabled()) {
      before = new Rectangle(rect);
    }
    ScreenUtil.fitToScreen(rect);
    if (LOG.isDebugEnabled() && !Objects.equals(before, rect)) {
      LOG.debug("Fitted these bounds to the screen: " + before + " -> " + rect);
    }
  }
@ApiStatus.Internal
  public void fitToScreen(Rectangle rect)