StylusPoint.Equals メソッド
定義
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
2 つの StylusPoint オブジェクトが等しいかどうかを比較します。
オーバーロード
| 名前 | 説明 |
|---|---|
| Equals(Object) |
指定したオブジェクトが StylusPointと等しいかどうかを示す値を返します。 |
| Equals(StylusPoint) |
指定した StylusPoint が現在の StylusPointと等しいかどうかを示すブール値を返します。 |
| Equals(StylusPoint, StylusPoint) |
指定した 2 つの StylusPoint オブジェクトが等しいかどうかを示すブール値を返します。 |
Equals(Object)
指定したオブジェクトが StylusPointと等しいかどうかを示す値を返します。
public:
override bool Equals(System::Object ^ o);
public override bool Equals(object o);
override this.Equals : obj -> bool
Public Overrides Function Equals (o As Object) As Boolean
パラメーター
- o
- Object
現在のStylusPointと比較するStylusPoint。
返品
true オブジェクトが等しい場合。それ以外の場合は false。
例
次の例では、2 つの StylusPoint オブジェクトの等価性をチェックします。
XとYのPressureFactor、point1、およびpoint2プロパティは同じ値に設定されているため、"2 つの StylusPoint オブジェクトは等しい" です。メッセージが表示されます。
StylusPoint point1 = new StylusPoint();
StylusPoint point2 = new StylusPoint();
point1.X = 150;
point1.Y = 400;
point1.PressureFactor = 0.45f;
point2.X = 150;
point2.Y = 400;
point2.PressureFactor = 0.45f;
Dim point1 As New StylusPoint()
Dim point2 As New StylusPoint()
point1.X = 150
point1.Y = 400
point1.PressureFactor = 0.45F
point2.X = 150
point2.Y = 400
point2.PressureFactor = 0.45F
if (point2.Equals(point1))
{
MessageBox.Show("The two StylusPoint objects are equal.");
}
else
{
MessageBox.Show("The two StylusPoint objects are not equal.");
}
If point2.Equals(point1) Then
MessageBox.Show("The two StylusPoint objects are equal.")
Else
MessageBox.Show("The two StylusPoint objects are not equal.")
End If
適用対象
Equals(StylusPoint)
指定した StylusPoint が現在の StylusPointと等しいかどうかを示すブール値を返します。
public:
virtual bool Equals(System::Windows::Input::StylusPoint value);
public bool Equals(System.Windows.Input.StylusPoint value);
override this.Equals : System.Windows.Input.StylusPoint -> bool
Public Function Equals (value As StylusPoint) As Boolean
パラメーター
- value
- StylusPoint
現在のStylusPointと比較するStylusPoint。
返品
true
StylusPoint オブジェクトが等しい場合は ɧ。それ以外の場合はfalse。
実装
例
次の例では、2 つの StylusPoint オブジェクトの等価性をチェックします。
XとYのPressureFactor、point1、およびpoint2プロパティは同じ値に設定されているため、"2 つの StylusPoint オブジェクトは等しい" です。メッセージが表示されます。
StylusPoint point1 = new StylusPoint();
StylusPoint point2 = new StylusPoint();
point1.X = 150;
point1.Y = 400;
point1.PressureFactor = 0.45f;
point2.X = 150;
point2.Y = 400;
point2.PressureFactor = 0.45f;
Dim point1 As New StylusPoint()
Dim point2 As New StylusPoint()
point1.X = 150
point1.Y = 400
point1.PressureFactor = 0.45F
point2.X = 150
point2.Y = 400
point2.PressureFactor = 0.45F
if (point2.Equals(point1))
{
MessageBox.Show("The two StylusPoint objects are equal.");
}
else
{
MessageBox.Show("The two StylusPoint objects are not equal.");
}
If point2.Equals(point1) Then
MessageBox.Show("The two StylusPoint objects are equal.")
Else
MessageBox.Show("The two StylusPoint objects are not equal.")
End If
適用対象
Equals(StylusPoint, StylusPoint)
指定した 2 つの StylusPoint オブジェクトが等しいかどうかを示すブール値を返します。
public:
static bool Equals(System::Windows::Input::StylusPoint stylusPoint1, System::Windows::Input::StylusPoint stylusPoint2);
public static bool Equals(System.Windows.Input.StylusPoint stylusPoint1, System.Windows.Input.StylusPoint stylusPoint2);
static member Equals : System.Windows.Input.StylusPoint * System.Windows.Input.StylusPoint -> bool
Public Shared Function Equals (stylusPoint1 As StylusPoint, stylusPoint2 As StylusPoint) As Boolean
パラメーター
- stylusPoint1
- StylusPoint
比較する最初の StylusPoint 。
- stylusPoint2
- StylusPoint
比較する 2 つ目の StylusPoint 。
返品
true
StylusPoint オブジェクトが等しい場合は ɧ。それ以外の場合はfalse。
例
次の例では、2 つの StylusPoint オブジェクトの等価性をチェックします。
XとYのPressureFactor、point1、およびpoint2プロパティは同じ値に設定されているため、"2 つの StylusPoint オブジェクトは等しい" です。メッセージが表示されます。
StylusPoint point1 = new StylusPoint();
StylusPoint point2 = new StylusPoint();
point1.X = 150;
point1.Y = 400;
point1.PressureFactor = 0.45f;
point2.X = 150;
point2.Y = 400;
point2.PressureFactor = 0.45f;
Dim point1 As New StylusPoint()
Dim point2 As New StylusPoint()
point1.X = 150
point1.Y = 400
point1.PressureFactor = 0.45F
point2.X = 150
point2.Y = 400
point2.PressureFactor = 0.45F
if (StylusPoint.Equals(point1, point2))
{
MessageBox.Show("The two StylusPoint objects are equal.");
}
else
{
MessageBox.Show("The two StylusPoint objects are not equal.");
}
If StylusPoint.Equals(point1, point2) Then
MessageBox.Show("The two StylusPoint objects are equal.")
Else
MessageBox.Show("The two StylusPoint objects are not equal.")
End If