Implement whitespace management extension using fo:multi-switch Patch from 13/10/28 by Seifeddine Dridi, applied with some modifications.