I’m trying to create a user control in WPF to represent a Go board, which is essentially just a grid of black lines with dots on some of the intersections.
At the moment I’m using a Grid control to handle placement of the stones, but one of the difficulties is that the stones are placed on the intersections of the gridlines rather than between them, so if I want to draw the lines, they need to go through the centres of the grid cells.
I’m still quite new to WPF so I’m not really sure how I should be approaching this; should I be manually painting the lines every time the control renders (if so, how?), or is there a better way?
I just added this post in my blog:
EDIT:
Moved the file to my Google drive
I think it’ll help you, this is the result you’ll get. You can download the projet in there too.