If minimumY evaluates to Infinity or NaN, use 0 instead