Skip to content

Commit fd9f267

Browse files
authored
Update image.md
This is missing, but this is an important information. Imagine a view sized 100x150 and an image sized 200x300. The old description could be interpreted in a way, that the image doesn't scale at all!
1 parent df09742 commit fd9f267

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

docs/image.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -395,7 +395,9 @@ More details about `resize` and `scale` can be found at http://frescolib.org/doc
395395

396396
Determines how to resize the image when the frame doesn't match the raw image dimensions. Defaults to `cover`.
397397

398-
- `cover`: Scale the image uniformly (maintain the image's aspect ratio) so that both dimensions (width and height) of the image will be equal to or larger than the corresponding dimension of the view (minus padding).
398+
- `cover`: Scale the image uniformly (maintain the image's aspect ratio) so that
399+
* both dimensions (width and height) of the image will be equal to or larger than the corresponding dimension of the view (minus padding)
400+
* at least one dimension of the scaled image will be equal to the corresponding dimension of the view (minus padding)
399401

400402
- `contain`: Scale the image uniformly (maintain the image's aspect ratio) so that both dimensions (width and height) of the image will be equal to or less than the corresponding dimension of the view (minus padding).
401403

0 commit comments

Comments
 (0)