QRectF::contains() considers right and bottom edges inside the rectangle, but the relevant code has the opposite expectations.