Skip to content

Commit

Permalink
Update image.md
Browse files Browse the repository at this point in the history
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!
  • Loading branch information
erheron committed Nov 17, 2021
1 parent df09742 commit fd9f267
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion docs/image.md
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,9 @@ More details about `resize` and `scale` can be found at http://frescolib.org/doc

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

- `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).
- `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)
* at least one dimension of the scaled image will be equal to the corresponding dimension of the view (minus padding)

- `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).

Expand Down

0 comments on commit fd9f267

Please sign in to comment.