This method returns fractional sizes (in the size component of the returned CGRect); to use a returned size to size views, you must raise its value to the nearest higher integer using the ceil function.
って書いてあった。
なのでよしなに ceil する。
CGRect calcRect = [str boundingRectWithSize:CGSizeMake(maxWidth, maxHeight)
options:NSStringDrawingUsesLineFragmentOrigin
attributes:@{NSFontAttributeName : font}
context:nil];
return CGRectMake( x, y,
ceil( calcRect.size.width ), ceil( calcRect.size.height ));