I am trying to create effects in WPF such as rail tracks and streets with borders and labels. How to add a border to a line segment and a label located along a line segment? I tried the Border class, but it creates a rectangular border.

For the shortcut, I tried Text along the way , but it takes a lot of time to process, since I have> 5000 lines on the canvas.
Any pointers to resources, tips, examples will be very helpful and appreciated.
Thanks!
source share