documentation, finished some TODOS and FIXMEs