Apply Trejkax's fix from bug #41653, and do a whole load of tests for the HWPF picture stuff. Includes a stub test for the problem identified in bug #41898