How can I have different colors for FROMarrow and TOarrow? I’d like to have one color at start of link arrowhead and a different color at end of link arrowhead. (VB.net)
There’s only a single Brush property for the whole link, so you will need to override a GoLink method to paint the “from” arrowhead yourself, while allowing the standard painting to work for the “to” arrowhead.I believe the method you want to override is GoLink.DrawArrowhead.
Any sample VB code to accomplish this. I really have no idea (or time to figure it out).
Here a simple example:
Protected Overrides Sub DrawArrowhead(g As Graphics, view As GoView, pen As Pen, brush As Brush, atEnd As Boolean, offsetw As Single, offseth As Single, poly() As PointF)
If atEnd Then
Dim b As New SolidBrush(Color.Red)
MyBase.DrawArrowhead(g, view, pen, b, atEnd, offsetw, offseth, poly)
MyBase.DrawArrowhead(g, view, pen, brush, atEnd, offsetw, offseth, poly)
End Sub 'DrawArrowhead
End Class 'ColoredArrowheadLink