Fan

 

const class

gfx::Point

sys::Obj
  gfx::Point

@simple
@js

Point represents a coordinate in the display space.

Slots

defValSource

static Point defVal := Point(0, 0)

Default instance is 0, 0.

equalsSource

override Bool equals(Obj? obj)

Overrides sys::Obj.equals

Return if obj is same Point value.

fromStrSource

static Point? fromStr(Str s, Bool checked := true)

Parse from string. If invalid and checked is true then throw ParseErr otherwise return null.

hashSource

override Int hash()

Overrides sys::Obj.hash

Return hash of x and y.

makeSource

new make(Int x, Int y)

Construct with x, y.

toStrSource

override Str toStr()

Overrides sys::Obj.toStr

Return "x,y"

translateSource

Point translate(Point t)

Return x+tx, y+ty

xSource

const Int x

X coordinate

ySource

const Int y

Y coordinate