For the HPLIP upstream developers at HP: The Perl magic above adds the "/cupsInteger0 <PCL page size number>" also to the PostScript commands of the PageSize option of the hpcups driver (not only PageRegion). Please apply this change also to the upstream source code. Thanks.
I have a fix ready now, but I have to wait for bug #732638 to get fixed so that I can upload it.
Or if you want to try already, run the following command lines:
perl -e 'my $content = join("", <>); while($content =~ s:^(\s* CustomMedia. *?<<)(/ PageSize. *?>>.*? \n?.*?< <)(\/cupsIntege r0\s+\d+ )(.*>>. *)$:\1\ 3\2\3\4: smgi) {}; print $content' /usr/share/ cups/drv/ hpcups. drv > hpcups.drv.new cups/drv/ hpcups. drv
sudo mv -f hpcups.drv.new /usr/share/
Then remove and recreate your print queue.
For the HPLIP upstream developers at HP: The Perl magic above adds the "/cupsInteger0 <PCL page size number>" also to the PostScript commands of the PageSize option of the hpcups driver (not only PageRegion). Please apply this change also to the upstream source code. Thanks.