本文整理汇总了Golang中github.com/platinasystems/weeb/r2.X.Y方法的典型用法代码示例。如果您正苦于以下问题:Golang X.Y方法的具体用法?Golang X.Y怎么用?Golang X.Y使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类github.com/platinasystems/weeb/r2.X
的用法示例。
在下文中一共展示了X.Y方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Golang代码示例。
示例1: StrokeText
func (c *Context) StrokeText(text string, x r2.X, maxWidth ...float64) {
if len(maxWidth) > 0 {
c.Call("strokeText", text, x.X(), x.Y(), maxWidth)
} else {
c.Call("strokeText", text, x.X(), x.Y())
}
}
示例2: StrokeRect
func (c *Context) StrokeRect(x, s r2.X) { c.Call("strokeRect", x.X(), x.Y(), s.X(), s.Y()) }
示例3: ClearRect
func (c *Context) ClearRect(x, s r2.X) { c.Call("clearRect", x.X(), x.Y(), s.X(), s.Y()) }
示例4: IsPointInPath
func (c *Context) IsPointInPath(x r2.X) { c.Call("isPointInPath", x.X(), x.Y()) }
示例5: FillRect
func (c *Context) FillRect(x, s r2.X) { c.Call("fillRect", x.X(), x.Y(), s.X(), s.Y()) }
示例6: Translate
func (c *Context) Translate(x r2.X) { c.Call("translate", x.X(), x.Y()) }
示例7: SetTransform
// Resets transform to DX 0 and identity matrix then applies given transform.
func (c *Context) SetTransform(m00, m01, m10, m11 float64, dx r2.X) {
c.Call("setTransform", m00, m01, m10, m11, dx.X(), dx.Y())
}
示例8: ArcTo
func (c *Context) ArcTo(x1, x2 r2.X, r float64) { c.Call("arcTo", x1.X(), x1.Y(), x2.X(), x2.Y(), r) }
示例9: Scale
// Transforms
func (c *Context) Scale(x r2.X) { c.Call("scale", x.X(), x.Y()) }
示例10: Arc
func (c *Context) Arc(x r2.X, r float64, θ0, θ1 r2.Angle, ccw ...bool) {
c.Call("arc", x.X(), x.Y(), r, θ0.Radians(), θ1.Radians(), ccw)
}
示例11: Ellipse
func (c *Context) Ellipse(x, r r2.X, θ0, θ1, rotation r2.Angle, ccw ...bool) {
c.Call("ellipse", x.X(), x.Y(), r.X(), r.Y(), rotation.Radians(), θ0.Radians(), θ1.Radians(), ccw)
}
示例12: BezierCurveTo
func (c *Context) BezierCurveTo(c1, c2, x1 r2.X) {
c.Call("bezierCurveTo", c1.X(), c1.Y(), c2.X(), c2.Y(), x1.X(), x1.Y())
}
示例13: QuadraticCurveTo
func (c *Context) QuadraticCurveTo(c1, x1 r2.X) {
c.Call("quadraticCurveTo", c1.X(), c1.Y(), x1.X(), x1.Y())
}
示例14: Rect
func (c *Context) Rect(x, s r2.X) { c.Call("rect", x.X(), x.Y(), s.X(), s.Y()) }
示例15: LineTo
func (c *Context) LineTo(x r2.X) { c.Call("lineTo", x.X(), x.Y()) }