Addressed Ambiguity in transform.scale constructor docs (#128182)

This PR updates the docs for Transform.Scale constructor by clearing up some ambiguity regarding how the scaling factor is affected by the omission of a value given you provide scaleX and scaleY as arguments as opposed to just scale

addresses bug [126822](https://github.com/flutter/flutter/issues/126822)

- [X ] I read the [Contributor Guide] and followed the process outlined there for submitting PRs.
- [X ] I read the [Tree Hygiene] wiki page, which explains my responsibilities.
- [ X] I read and followed the [Flutter Style Guide], including [Features we expect every widget to implement].
- [X ] I signed the [CLA].
- [X ] I listed at least one issue that this PR fixes in the description above.
- [ X] I updated/added relevant documentation (doc comments with `///`).
- [ X] I added new tests to check the change I am making, or this PR is [test-exempt].
- [X ] All existing and new tests are passing.
This commit is contained in:
Alex Fischer 2023-06-06 20:11:48 -07:00 committed by GitHub
parent 02e9d51527
commit 19f85935ca
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1371,7 +1371,7 @@ class Transform extends SingleChildRenderObjectWidget {
/// Creates a widget that scales its child along the 2D plane.
///
/// The `scaleX` argument provides the scalar by which to multiply the `x` axis, and the `scaleY` argument provides the scalar by which to multiply the `y` axis. Either may be omitted, in which case that axis defaults to 1.0.
/// The `scaleX` argument provides the scalar by which to multiply the `x` axis, and the `scaleY` argument provides the scalar by which to multiply the `y` axis. Either may be omitted, in which case the scaling factor for that axis defaults to 1.0.
///
/// For convenience, to scale the child uniformly, instead of providing `scaleX` and `scaleY`, the `scale` parameter may be used.
///