#106094Exception in ImageProcessingInstructions if calculated maxWidth is float
Description
To reproduce:
Add a svg image with eg. 400 × 400 px (example image attached) as page thumbnail (via page properties using EXT:bootstrap_package). Add a menu content element “cards from subpages” to another page and select the parent page of the previous added page with the svg page thumbnail.
Open the page with the menu and you will get the following exception:
```
TYPO3\CMS\Core\Imaging\ImageProcessingInstructions::__construct(): Argument #1 ($width) must be of type int, float given, called in /var/www/html/vendor/typo3/cms-core/Classes/Imaging/ImageProcessingInstructions.php on line 231
```
The cause is a missing int cast at the returned width and height values of the static method ImageProcessingInstructions::fromCropScaleValues.
This problem can easily fixed by changing line 231-235 from this:
```
return new self(
width: $width,
height: $height,
cropArea: $cropArea,
);
```
to this:
```
return new self(
width: (int)$width,
height: (int)$height,
cropArea: $cropArea,
);
```
Reviews 4
- main 88522[BUGFIX] Add missing integer casting to ImageProcessing minHeight case
- 13.4 88523[BUGFIX] Add missing integer casting to ImageProcessing minHeight case
- 13.4 88238[BUGFIX] Fix failing image generation for width/height 0 thumbnails
- main 88206[BUGFIX] Fix failing image generation for width/height 0 thumbnails