Some cleanup and doxygen documentation

Cleaned some code, modified nodegraph functions and added doxygen
documentation.

New nodes are now added to the position where user right-clicked and if
one node is selected, new node will be inserted after that and all edges
get correctly connected.

Started to rip out built-in ops to be replaced entirely with external
plugins, but seems I also broke something... not sure exactly what yet
:)