Reenable custom header/footer printing.

This feature was disabled in the initial Qt5 port, due to missing
support on the qtwebkit side. Now, with the patch applied for qtwebkit
again, the commit reenables the feature.