Removed a lot of obsolete code from the old page breaking approach. Some style improvements here and there.