I also struggled a bit with figuring out a way to do this. Basically, every Symbol you draw is converted into a 16x16 grid where pixels are either black or white, depending on wheter you drew in them or not. We then trained an artificial neural network on about 4000 self-drawn symbols, and when a User draws a symbol, that neural network decides what symbol it is. Took a few tries but now it's pretty acurate, at least for our handwriting :)
It's a really interesting topic, definitely check it out if you're interested. For Godot, for example, there exists an ANN Plugin, it's linked on the game page