BL-705: Restrict the range of pages 'printed' to make PDF

Restrict the range of pages printed to the ones that actually exist,
which prevents Gecko adding an extra blank one.
It seems the new version of this took me a lot longer to understand than the original, since it first introduces a version that, if I'm reading this right, is never used. And I can't tell what you were after...  just giving a name to the predicate? Could you do that by just declaring it a single time outside of the switch and then using it in both of the calls to HidePages()?