The angle at which to rotate the view. それでこのビューを回転する角度。
Instance Method
インスタンスメソッド
rotation
rotationEffect(_:anchor:)
Rotates this view’s rendered output around the specified point.
このビューのもつ描画された出力をこの指定された点を中心として回転します。
Availability 有効性
- iOS 13.0+
- iPadOS 13.0+
- macOS 10.15+
- Mac Catalyst 13.0+
- tvOS 13.0+
- watchOS 6.0+
Technology
- Swift
UI
Declaration 宣言
Parameters パラメータ
angle
anchor
The location with a default of
center
that defines a point at which the rotation is anchored.
Discussion 議論
Use rotation
to rotate the view by a specific amount.
In the example below, the text is rotated by 22˚.
Text("Rotation by passing an angle in degrees")
.rotationEffect(.degrees(22))
.border(Color.gray)