Yes, thanks, Klaus.
But also such changes helps to make the pin of correct size:
B4X:
Public mLine, mPoint1, mPoint2 As B4XView, mRoot As B4XView
Public LineThinknessPx As Int = 2dip
Public LineLenghtPx As Int = 20dip
Public LineColor As Int = xui.Color_Blue
Private PointSizePx As Int = LineThinknessPx * 5 'here is important