public final class PointF extends com.aspose.ms.lang.Struct<PointF>
Represents an ordered pair of floating-point x- and y-coordinates that defines a point in a two-dimensional plane.
| Constructor and Description |
|---|
PointF() |
PointF(float x,
float y)
Initializes a new instance of the
com.aspose.imaging.PointF structure with the specified coordinates. |
| Modifier and Type | Method and Description |
|---|---|
static PointF |
add(PointF point,
Size size)
Translates a given
com.aspose.imaging.PointF by the specified com.aspose.imaging.Size. |
static PointF |
add(PointF point,
SizeF size)
Translates a given
com.aspose.imaging.PointF by a specified com.aspose.imaging.SizeF. |
PointF |
Clone() |
void |
CloneTo(PointF that) |
boolean |
equals(Object obj)
Specifies whether this
com.aspose.imaging.PointF contains the same coordinates as the specified System.Object. |
static PointF |
getEmpty()
Gets a new instance of the
com.aspose.imaging.PointF structure that has com.aspose.imaging.PointF.X and com.aspose.imaging.PointF.Y values set to zero. |
float |
getX()
Gets or sets the x-coordinate of this
com.aspose.imaging.PointF. |
float |
getY()
Gets or sets the y-coordinate of this
com.aspose.imaging.PointF. |
int |
hashCode()
Returns a hash code for this
com.aspose.imaging.PointF structure. |
boolean |
isEmpty()
Gets a value indicating whether this
com.aspose.imaging.PointF is empty. |
static boolean |
isEquals(PointF obj1,
PointF obj2) |
static PointF |
op_Addition(PointF point,
Size size)
Translates a
com.aspose.imaging.PointF by a given com.aspose.imaging.Size. |
static PointF |
op_Addition(PointF point,
SizeF size)
Translates the
com.aspose.imaging.PointF by the specified com.aspose.imaging.SizeF. |
static boolean |
op_Equality(PointF point1,
PointF point2)
Compares two
com.aspose.imaging.PointF structures. |
static boolean |
op_Inequality(PointF point1,
PointF point2)
Determines whether the coordinates of the specified points are not equal.
|
static PointF |
op_Subtraction(PointF point,
Size size)
Translates a
com.aspose.imaging.PointF by the negative of a given com.aspose.imaging.Size. |
static PointF |
op_Subtraction(PointF point,
SizeF size)
Translates a
com.aspose.imaging.PointF by the negative of a specified com.aspose.imaging.SizeF. |
void |
setX(float value)
Gets or sets the x-coordinate of this
com.aspose.imaging.PointF. |
void |
setY(float value)
Gets or sets the y-coordinate of this
com.aspose.imaging.PointF. |
static PointF |
subtract(PointF point,
Size size)
Translates a
com.aspose.imaging.PointF by the negative of a specified size. |
static PointF |
subtract(PointF point,
SizeF size)
Translates a
com.aspose.imaging.PointF by the negative of a specified size. |
String |
toString()
Converts this
com.aspose.imaging.PointF to a human readable string. |
public PointF()
public PointF(float x,
float y)
Initializes a new instance of the com.aspose.imaging.PointF structure with the specified coordinates.
x - The horizontal position of the point.y - The vertical position of the point.public static PointF getEmpty()
Gets a new instance of the com.aspose.imaging.PointF structure that has com.aspose.imaging.PointF.X and com.aspose.imaging.PointF.Y values set to zero.
public static PointF op_Addition(PointF point, Size size)
Translates a com.aspose.imaging.PointF by a given com.aspose.imaging.Size.
point - The com.aspose.imaging.PointF to translate.size - A com.aspose.imaging.Size that specifies the pair of numbers to add to the coordinates of point.com.aspose.imaging.PointF.public static PointF op_Subtraction(PointF point, Size size)
Translates a com.aspose.imaging.PointF by the negative of a given com.aspose.imaging.Size.
point - A com.aspose.imaging.PointF to translate.size - A com.aspose.imaging.Size that specifies the numbers to subtract from the x- and y-coordinates of the point.com.aspose.imaging.PointF.public static PointF op_Addition(PointF point, SizeF size)
Translates the com.aspose.imaging.PointF by the specified com.aspose.imaging.SizeF.
point - The com.aspose.imaging.PointF to translate.size - The com.aspose.imaging.SizeF that specifies the numbers to add to the x- and y-coordinates of the point.com.aspose.imaging.PointF.public static PointF op_Subtraction(PointF point, SizeF size)
Translates a com.aspose.imaging.PointF by the negative of a specified com.aspose.imaging.SizeF.
point - The com.aspose.imaging.PointF to translate.size - The com.aspose.imaging.SizeF that specifies the numbers to subtract from the coordinates of point.com.aspose.imaging.PointF.public static boolean op_Equality(PointF point1, PointF point2)
Compares two com.aspose.imaging.PointF structures. The result specifies whether the values of the com.aspose.imaging.PointF.X and com.aspose.imaging.PointF.Y properties of the two com.aspose.imaging.PointF structures are equal.
point1 - A first com.aspose.imaging.PointF to compare.point2 - A second com.aspose.imaging.PointF to compare.com.aspose.imaging.PointF.X and com.aspose.imaging.PointF.Y values of the first and second com.aspose.imaging.PointF structures are equal; otherwise, false.public static boolean op_Inequality(PointF point1, PointF point2)
Determines whether the coordinates of the specified points are not equal.
point1 - A first com.aspose.imaging.PointF to compare.point2 - A second com.aspose.imaging.PointF to compare.com.aspose.imaging.PointF.X and com.aspose.imaging.PointF.Y values of point1 and point2 are not equal; otherwise, false.public static PointF add(PointF point, Size size)
Translates a given com.aspose.imaging.PointF by the specified com.aspose.imaging.Size.
point - The com.aspose.imaging.PointF to translate.size - The com.aspose.imaging.Size that specifies the numbers to add to the coordinates of point.com.aspose.imaging.PointF.public static PointF subtract(PointF point, Size size)
Translates a com.aspose.imaging.PointF by the negative of a specified size.
point - The com.aspose.imaging.PointF to translate.size - The com.aspose.imaging.Size that specifies the numbers to subtract from the coordinates of point.com.aspose.imaging.PointF.public static PointF add(PointF point, SizeF size)
Translates a given com.aspose.imaging.PointF by a specified com.aspose.imaging.SizeF.
point - The com.aspose.imaging.PointF to translate.size - The com.aspose.imaging.SizeF that specifies the numbers to add to the coordinates of point.com.aspose.imaging.PointF.public static PointF subtract(PointF point, SizeF size)
Translates a com.aspose.imaging.PointF by the negative of a specified size.
point - The com.aspose.imaging.PointF to translate.size - The com.aspose.imaging.SizeF that specifies the numbers to subtract from the coordinates of point.com.aspose.imaging.PointF.public boolean isEmpty()
Gets a value indicating whether this com.aspose.imaging.PointF is empty.
com.aspose.imaging.PointF.X and com.aspose.imaging.PointF.Y are 0; otherwise, false.public float getX()
Gets or sets the x-coordinate of this com.aspose.imaging.PointF.
public void setX(float value)
Gets or sets the x-coordinate of this com.aspose.imaging.PointF.
public float getY()
Gets or sets the y-coordinate of this com.aspose.imaging.PointF.
public void setY(float value)
Gets or sets the y-coordinate of this com.aspose.imaging.PointF.
public boolean equals(Object obj)
Specifies whether this com.aspose.imaging.PointF contains the same coordinates as the specified System.Object.
public int hashCode()
Returns a hash code for this com.aspose.imaging.PointF structure.
public String toString()
Converts this com.aspose.imaging.PointF to a human readable string.
public void CloneTo(PointF that)
CloneTo in class com.aspose.ms.System.ValueType<PointF>Copyright (c) 2008-2025 Aspose Pty Ltd. All Rights Reserved.