STYLE: adjust formatting and remove some unused code
BUG: fixes to make it compile outside Slicer
COMP: add back typedef