You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-dev@xmlgraphics.apache.org by "christian.pestel (JIRA)" <ji...@apache.org> on 2015/02/11 15:23:11 UTC

[jira] [Commented] (FOP-2449) PostScript extension ps-setpagedevice with Xerox7835 printer trays

    [ https://issues.apache.org/jira/browse/FOP-2449?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14316248#comment-14316248 ] 

christian.pestel commented on FOP-2449:
---------------------------------------

Fop config
<renderer mime="application/postscript">

  <auto-rotate-landscape>false</auto-rotate-landscape>
  <language-level>3</language-level>
  <optimize-resources>true</optimize-resources>
  <safe-set-page-device>false</safe-set-page-device>
  <dsc-compliant>true</dsc-compliant>
  <rendering>quality</rendering>

> PostScript extension ps-setpagedevice with Xerox7835 printer trays
> ------------------------------------------------------------------
>
>                 Key: FOP-2449
>                 URL: https://issues.apache.org/jira/browse/FOP-2449
>             Project: Fop
>          Issue Type: Improvement
>          Components: renderer/ps
>    Affects Versions: 1.1
>            Reporter: christian.pestel
>             Fix For: trunk
>
>         Attachments: Trays_KO_page_1.png, Trays_KO_page_2.png, Trays_ok_page_1.png, Trays_ok_page_2.png, test.trays_KO.fo, test.trays_KO.ps, test.trays_ok.fo, test.trays_ok.ps
>
>
> With LaserJet,  trays PostScript instruction are 
> for Tray 1 : /MediaPosition 1
> for Tray 2 : /MediaPosition 2
>  
> With Xerox :
> for Tray 1 : (tray1) xerox$MediaInputTray 
> for Tray 2 : (tray2) xerox$MediaInputTray 
> Here is an extract of my IF file (Intermediate Format) for LaserJet :
> PS file for LaserJet :
> Page 1 : 
> %FOPBeginSetPageDevice
> <<
> /PageSize [595 842]
> /MediaPosition 1
> /ImagingBBox null
> >> setpagedevice
> %FOPEndSetPageDevice
> Page 2 :
> %FOPBeginSetPageDevice
> <<
> /PageSize [595 842]
> /MediaPosition 2
> /ImagingBBox null
> >> setpagedevice
> %FOPEndSetPageDevice
> PS file for Xerox :
> Page 1 : 
> %FOPBeginSetPageDevice
> <<
> /PageSize [595 842]
> (tray1) xerox$MediaInputTray    <=====  correct/ImagingBBox null
> >> setpagedevice
> %FOPEndSetPageDevice
> Page 2 :
> %FOPBeginSetPageDevice
> <<
> /PageSize [595 842]
> (tray1) xerox$MediaInputTray <=====  incorrect
> (tray2) xerox$MediaInputTray  <===== only this line is correct 
> /ImagingBBox null
> >> setpagedevice
> %FOPEndSetPageDevice
> I have analysed the fop source code.
> In fact, Fop use a key/Value HashTable and all new  key/value are cumulative.  
> With LaserJet 
> Page 1 : key=/MediaPosition and value=1   => Fop write in PostScript : “/MediaPosition 1”
> Page 2 : key=/MediaPosition and value=2   => Fop write in PostScript : “/MediaPosition 2”
> With Xerox :
> Page 1 : key=(tray1) and value=xerox$MediaInputTray    => Fop write in PostScript : “(tray1) xerox$MediaInputTray” 
> Page 2 : key=(tray2) and value=xerox$MediaInputTray    => Fop write in PostScript all keys/values  : “(tray1) xerox$MediaInputTray” + “(tray2) xerox$MediaInputTray”



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)