Implemented staff line merging.  Need to work on performance later, it is very slow.