$dimensions->fitWidthAndHeight()
Recalculates the dimensions by the width and height
Parameters
Name | Type | Default | Description |
---|---|---|---|
$width | int |
null |
the max height |
$height | int |
null |
the max width |
$force | bool |
false |
Return type
This method does not modify the existing $dimensions
object but returns a new object with the changes applied. Learn more →