Refactor F keys, sets gundo settings. Set up folding.