mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-03 20:49:27 +00:00
Bug 283437 [Postscript] If the page size is not set correctly, there will be a PostScript error "configurationerror".
Patch by leon.sha@sun.com. kherron+mozilla: review+ roc: superreview+
This commit is contained in:
parent
ce53511c15
commit
0486acc879
@ -460,13 +460,12 @@ nsPostScriptObj::write_prolog(FILE *aHandle, PRBool aFTPEnable)
|
|||||||
// Tell the printer what size paper it should use
|
// Tell the printer what size paper it should use
|
||||||
fprintf(f,
|
fprintf(f,
|
||||||
"/setpagedevice where\n" // Test for the feature
|
"/setpagedevice where\n" // Test for the feature
|
||||||
"{ pop\n"
|
"{ pop 2 dict\n"
|
||||||
" <<\n"
|
" dup /PageSize [ %s %s ] put\n" // Paper dimensions
|
||||||
" /PageSize [ %s %s ]\n" // Paper dimensions
|
" dup /Policies 1 dict\n"
|
||||||
" /Policies <<\n"
|
" dup /PageSize 3 put\n" // Select the nearest page size to fit
|
||||||
" /PageSize 3\n" // Select the nearest page size to fit
|
" put\n"
|
||||||
" >>\n"
|
" setpagedevice\n" // Install settings
|
||||||
" >> setpagedevice\n" // Install settings
|
|
||||||
"} if\n",
|
"} if\n",
|
||||||
fpCString(NSTwipsToFloatPoints(paper_width)).get(),
|
fpCString(NSTwipsToFloatPoints(paper_width)).get(),
|
||||||
fpCString(NSTwipsToFloatPoints(paper_height)).get());
|
fpCString(NSTwipsToFloatPoints(paper_height)).get());
|
||||||
|
Loading…
x
Reference in New Issue
Block a user