PixelPoint Structure

Represents a point in device pixels.

Definition

Namespace: Avalonia
Assembly: Avalonia.Base (in Avalonia.Base.dll) Version: 11.3.999
public readonly struct PixelPoint : IEquatable<PixelPoint>
Inheritance
Object    ValueType    PixelPoint
Implements
IEquatablePixelPoint

Properties

X Gets the X co-ordinate.
Y Gets the Y co-ordinate.

Methods

Equals(Object) Checks for equality between a point and an object.
(Overrides ValueTypeEquals(Object))
Equals(PixelPoint) Returns a boolean indicating whether the point is equal to the other given point.
FromPoint(Point, Vector) Converts a Point to device pixels using the specified scaling factor.
FromPoint(Point, Double) Converts a Point to device pixels using the specified scaling factor.
FromPointWithDpi(Point, Vector) Converts a Point to device pixels using the specified dots per inch (DPI).
FromPointWithDpi(Point, Double) Converts a Point to device pixels using the specified dots per inch (DPI).
GetHashCode Returns a hash code for a PixelPoint.
(Overrides ValueTypeGetHashCode)
GetTypeGets the Type of the current instance.
(Inherited from Object)
Parse(String) Parses a PixelPoint string.
ToPoint(Double) Converts the PixelPoint to a device-independent Point using the specified scaling factor.
ToPoint(Vector) Converts the PixelPoint to a device-independent Point using the specified scaling factor.
ToPointWithDpi(Double) Converts the PixelPoint to a device-independent Point using the specified dots per inch (DPI).
ToPointWithDpi(Vector) Converts the PixelPoint to a device-independent Point using the specified dots per inch (DPI).
ToString Returns the string representation of the point.
(Overrides ValueTypeToString)
WithX(Int32) Returns a new PixelPoint with the same Y co-ordinate and the specified X co-ordinate.
WithY(Int32) Returns a new PixelPoint with the same X co-ordinate and the specified Y co-ordinate.

Operators

Addition(PixelPoint, PixelPoint) Adds two points.
Addition(PixelPoint, PixelVector) Adds a vector to a point.
Equality(PixelPoint, PixelPoint) Checks for equality between two PixelPoints.
(PixelPoint to PixelVector) Converts the Point to a Vector.
Inequality(PixelPoint, PixelPoint) Checks for inequality between two PixelPoints.
Subtraction(PixelPoint, PixelPoint) Subtracts two points.
Subtraction(PixelPoint, PixelVector) Subtracts a vector from a point.

Fields

Origin A point representing 0,0.

See Also