Bug 688081

Summary: Using the RedMon PDF "printer" to print landscape-oriented pages actually yields portrait-oriented pages
Product: Ghostscript Reporter: Chris Verges <squirrel>
Component: PDF WriterAssignee: Russell Lang <gsview>
Status: RESOLVED FIXED    
Severity: normal CC: alex, christinedelight.top85, gsview
Priority: P3    
Version: 8.51   
Hardware: PC   
OS: Windows 2000   
URL: http://www.stat.tamu.edu/~henrik/GSWriter/GSWriter.html
Customer: Word Size: ---
Attachments: A sample of the improper page orientation
Postscript file
PDF file

Description Chris Verges 2005-05-09 12:38:27 UTC
When printing out a PDF from another program (i.e. Visio) using the RedMon PDF
converter (as installed via the instructions at
http://www.stat.tamu.edu/~henrik/GSWriter/GSWriter.html, a problem was noticed
when the page orientation was set to landscape.  The content of the page was
oriented as such, but the page itself had a portrait orientation in the PDF.

Example:

  The page in Visio:
     +---------------+
     | Page 1        |
     |   Page 1      |
     |     Page 1    |
     +---------------+

  The PDF output:
     +-----+
     |    1|
     |     |
     |  1 E|     Characters are rotated to the proper orientation, but
     |    G|     I can't simulate that in the bug report.
     |1 E A|
     |  G P|
     |E A  |
     |G P  |
     |A    |
     |P    |
     +-----+

  Expected output:
     +---------------+
     | Page 1        |
     |   Page 1      |
     |     Page 1    |
     +---------------+
Comment 1 Chris Verges 2005-05-09 12:41:32 UTC
Created attachment 1378 [details]
A sample of the improper page orientation
Comment 2 Stefan Kemper 2005-05-11 07:52:42 UTC
You can submit this as a bug against Visio, for failing to give good orientation
hints, against Redmon for failing to pass these hints on or act on them.  Us for
failing to interpet the hints, but without the visio output file I can't tell
where to look.  

For more information : 
http://bugs.ghostscript.com/show_bug.cgi?id=592930  
gs/doc/ps2pdf.htm

This is a common problem as applications expect you are printing to paper, which
uses the physical rotation method.  

*** This bug has been marked as a duplicate of 592930 ***
Comment 3 Chris Verges 2005-05-11 11:24:25 UTC
Stefan,

If you look at the attached PDF I sent you, this also happens with Notepad.  It
is probably a bug with RedMon given that two applications do not yield proper
results.  I'll refile under RedMon.

Thanks!
Comment 4 Russell Lang 2005-05-11 14:26:43 UTC
As Stefan wrote, we would need to see the original PostScript file fed by 
RedMon to Ghostscript.  There is a problem in ghostscript which hasn't yet 
been fixed. I need to complete testing of Distiller vs Ghostscript to work out 
exactly what behaviour is required, before any changes are made to ghostscript.
Comment 5 Chris Verges 2005-05-11 15:34:22 UTC
Hey Stefan,

After contacting the author of RedMon, it appears as though it is actually
something that Ghostscript doesn't process properly.  (His words, not mine.)

Since it looks like Ghostscript isn't processing %%ViewingOrientation, this is
still a valid bug entry, correct?

Thanks!



Quote from the e-mail:

In particular, ghostscript doesn't process %%ViewingOrientation 
correctly, which would probably have fixed this one.  You may get it 
to work by adding -dAutoRotatePages=/PageByPage to the ghostscript 
command line, but if some text is meant to be in the wrong direction 
then this will get confused.

Russell Lang                   gsview@ghostgum.com.au
Ghostgum Software Pty Ltd      http://www.ghostgum.com.au/
Comment 6 Chris Verges 2005-05-11 15:35:04 UTC
Russell,

Just tell me how to get you the original postscript file and I'll do it no problems.

Thanks!
Comment 7 Russell Lang 2005-05-12 04:45:00 UTC
Please attach the PostScript file to the bug report like the existing PDF file.
Comment 8 Chris Verges 2005-05-12 11:08:15 UTC
Created attachment 1384 [details]
Postscript file
Comment 9 Chris Verges 2005-05-12 11:11:35 UTC
Created attachment 1385 [details]
PDF file
Comment 10 Alex Cherepanov 2012-08-15 14:09:48 UTC
Recent version of Ghostscript correctly convert %%VievingOrientation
to /Rotate attribute.
This bug has been fixed for quite a while but the bug report has never
been closed. Closing now.