code: public boolean isWithinContentRect(float x, float y, float precision) {
          if (x >= contentRectMinusAllMargins.left - precision && x <= contentRectMinusAllMargins.right + precision) {
              if (y <= contentRectMinusAllMargins.bottom + precision && y >= contentRectMinusAllMargins.top -
                      precision) {
                  return true;
              }
          }
          return false;
      }
docs: Check if given coordinates lies inside contentRectMinusAllMargins.