I am trying to wrap my head around Drawpath, but nothing draws apart from "Testing".
Here is what I have so far:
B4XCanvas.DrawLine:
Log("-- Begin program")
Canvas1.Initialize(Panel1)
Dim left As Float = 200
Dim top As Float = 200
Dim myPath As B4XPath
myPath.Initialize(left, top)
myPath.LineTo(400, 200)
Canvas1.DrawPath(myPath, Colors.Black, True, 100)
Canvas1.DrawText("Testing", 200dip, 100dip, Font.DEFAULT, Colors.Red,"LEFT")
Canvas1.Invalidate
If you want to draw a filled path you need to add at least three points. If you want to draw just a line, you should set 'Filled' to false and reduce the 'StrokeWidth'.
If you want to draw a filled path you need to add at least three points. If you want to draw just a line, you should set 'Filled' to false and reduce the 'StrokeWidth'.