r7: Put code for handling pixmaps into some new files.