UITouch.GetAzimuthAngle(UIView) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Returns the rotation of the stylus relative to the plane of the screen, in radians.
[Foundation.Export("azimuthAngleInView:")]
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 9, 1, ObjCRuntime.PlatformArchitecture.All, null)]
[ObjCRuntime.Unavailable(ObjCRuntime.PlatformName.TvOS, ObjCRuntime.PlatformArchitecture.All, null)]
public virtual nfloat GetAzimuthAngle (UIKit.UIView view);
abstract member GetAzimuthAngle : UIKit.UIView -> nfloat
override this.GetAzimuthAngle : UIKit.UIView -> nfloat
Parameters
- view
- UIView
The UIView whose Transform defines the relative angle to be returned.
This parameter can be null
.
Returns
The default value is 0. The value returned is in the range [-π, +π]
- Attributes
Remarks
On supported hardware (see EstimatedProperties), this value returns the rotation, in radians, of the touching device (e.g., Apple Pencil) relative to the plane of the screen and the Transform of the view
. If view
is null
or uses the default transform, 0 radians corresponds to the right-hand side of the UIView, π radians correspond to the bottom of the UIView and so forth. (Note that in the default transform, Y increases towards the bottom of the view, so radians increase clockwise.)
This method is slightly more expensive than GetAzimuthUnitVector(UIView).
Applies to
See also
- <xref:UIKit.UITouch.GetAzimuthUnitVector>