Reorganized appearance and buffer/file code.