public float getElementEndX(float startX) {
    FoldRegion fold = getCurrentFold();
    if (fold == null) {
      int codePoint = getCodePoint();
      if (codePoint == '\t') {
        return EditorUtil.nextTabStop(startX + getInlaysPrefixWidth(), myView.getPlainSpaceWidth(), myView.getTabSize()) +
               getInlaysSuffixWidth();
      }
      else if (codePoint == '\r') { // can only happen when \n part of \r\n line break is folded
        return startX;
      }
      else {
        return startX + getInlaysPrefixWidth() + myView.getCodePointWidth(codePoint, getFontStyle()) + getInlaysSuffixWidth();
      }
    }
    else {
      return startX + myView.getFoldRegionLayout(fold).getWidth();
    }
  }
public float getElementEndX(float startX)