Merged TkTech's cleanup/revamp