phoenix_title wx.Point2D


class_hierarchy Class Hierarchy

Inheritance diagram for class Point2D:

method_summary Methods Summary

__init__

Get

Get() . (x,y)

GetCrossProduct

GetDistance

GetDistanceSquare

GetDotProduct

GetFloor

GetIM

Returns an immutable representation of the wx.Point2D object, based on namedtuple.

GetRounded

GetVectorAngle

GetVectorLength

Normalize

SetVectorAngle

SetVectorLength

__bool__

__getitem__

__len__

__nonzero__

__reduce__

__repr__

__setitem__

__str__

__ne__

__imul__

__iadd__

__sub__

__isub__

__idiv__

__eq__


property_summary Properties Summary

IM

See GetIM

VectorAngle

See GetVectorAngle and SetVectorAngle

VectorLength

See GetVectorLength and SetVectorLength

m_x

A public C++ attribute of type Double .

m_y

A public C++ attribute of type Double .


api Class API

class wx.Point2D(object)

Possible constructors:

Point2DDouble() -> None

Point2DDouble(x : float, y : float) -> None

Point2DDouble(pt : Point2DDouble) -> None

Point2DDouble(pt : Point) -> None

Methods

__init__(self, *args, **kw)

overload Overloaded Implementations:



__init__ (self)

Return type:

None



__init__ (self, x : float, y : float)

Parameters:
  • x (wx.Double) –

  • y (wx.Double) –

Return type:

None



__init__ (self, pt : Point2DDouble)

Parameters:

pt (Point2DDouble) –

Return type:

None



__init__ (self, pt : Point)

Parameters:

pt (wx.Point) –

Return type:

None





Get(self)

Get() . (x,y)

Return the x and y properties as a tuple.

Return type:

Any



GetCrossProduct(self, vec : Point2DDouble)
Parameters:

vec (Point2DDouble) –

Return type:

float



GetDistance(self, pt : Point2DDouble)
Parameters:

pt (Point2DDouble) –

Return type:

float



GetDistanceSquare(self, pt : Point2DDouble)
Parameters:

pt (Point2DDouble) –

Return type:

float



GetDotProduct(self, vec : Point2DDouble)
Parameters:

vec (Point2DDouble) –

Return type:

float



GetFloor(self)
Return type:

Tuple[int, int]



GetIM(self)

Returns an immutable representation of the wx.Point2D object, based on namedtuple.

This new object is hashable and can be used as a dictionary key, be added to sets, etc. It can be converted back into a real wx.Point2D with a simple statement like this: obj = wx.Point2D(imObj).



GetRounded(self)
Return type:

Tuple[int, int]



GetVectorAngle(self)
Return type:

float



GetVectorLength(self)
Return type:

float



Normalize(self)
Return type:

None



SetVectorAngle(self, degrees : float)
Parameters:

degrees (wx.Double) –

Return type:

None



SetVectorLength(self, length : float)
Parameters:

length (wx.Double) –

Return type:

None



__bool__(self)


__getitem__(self, idx)


__len__(self)


__nonzero__(self)


__reduce__(self)


__repr__(self)


__setitem__(self, idx, val)


__str__(self)


__ne__(self)
Parameters:

pt (Point2DDouble) –



__imul__(self)
Parameters:

pt (Point2DDouble) –



__iadd__(self)
Parameters:

pt (Point2DDouble) –



__sub__(self)


__isub__(self)
Parameters:

pt (Point2DDouble) –



__idiv__(self)
Parameters:

pt (Point2DDouble) –



__eq__(self)
Parameters:

pt (Point2DDouble) –


Properties

IM

See GetIM



VectorAngle

See GetVectorAngle and SetVectorAngle



VectorLength

See GetVectorLength and SetVectorLength



m_x

A public C++ attribute of type Double .



m_y

A public C++ attribute of type Double .