<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <p>Hi All,</p>
    <p>In continuation with the below mail, the issue is "collate"
      option is not checked for linux.</p>
    <p>Bug: <a class="moz-txt-link-freetext" href="https://bugs.openjdk.java.net/browse/JDK-8170352">https://bugs.openjdk.java.net/browse/JDK-8170352</a></p>
    <p>webrev: <a class="moz-txt-link-freetext" href="http://cr.openjdk.java.net/~psadhukhan/8170352/webrev.00/">http://cr.openjdk.java.net/~psadhukhan/8170352/webrev.00/</a><br>
    </p>
    <p>Proposed fix is to disable collate option for linux in printer
      dialog.<br>
    </p>
    Regards<br>
    Prasanta<br>
    <div class="moz-cite-prefix">On 12/8/2016 4:23 PM, Prasanta
      Sadhukhan wrote:<br>
    </div>
    <blockquote
      cite="mid:beb05a66-bf2d-ff16-47a8-291688670489@oracle.com"
      type="cite">
      <meta http-equiv="content-type" content="text/html; charset=utf-8">
      <p>Hi Phil,</p>
      <p>I was investigating JDK-8170352: The collate option is not
        checked and I found that CUPS does not report collate as
        supported attribute. <br>
      </p>
      It is removed from printRequestAttrib
      [<a moz-do-not-send="true" class="moz-txt-link-freetext"
href="http://hg.openjdk.java.net/jdk9/client/jdk/file/a21bac70753d/src/java.desktop/unix/classes/sun/print/IPPPrintService.java#l167">http://hg.openjdk.java.net/jdk9/client/jdk/file/a21bac70753d/src/java.desktop/unix/classes/sun/print/IPPPrintService.java#l167</a>]<br>
      so we do not look for collate-supported attribute in CUPS. Infact,
      getAttMap does not have any "collate-supported" attribute too!!<br>
      Also, this code
      [<a moz-do-not-send="true" class="moz-txt-link-freetext"
href="http://hg.openjdk.java.net/jdk9/client/jdk/file/a21bac70753d/src/java.desktop/unix/classes/sun/print/IPPPrintService.java#l1062">http://hg.openjdk.java.net/jdk9/client/jdk/file/a21bac70753d/src/java.desktop/unix/classes/sun/print/IPPPrintService.java#l1062</a>]
      has been added [for 8016737] <br>
      to remove SheetCollate from supported attributes.<br>
      <br>
      In light of this, I think we should disabled collate option from
      our print dialog even for Toolkit based PrintJob. It seems, from
      this code <br>
      <a moz-do-not-send="true" class="moz-txt-link-freetext"
href="http://hg.openjdk.java.net/jdk9/client/jdk/file/a21bac70753d/src/java.desktop/share/classes/sun/print/ServiceDialog.java#l1251">http://hg.openjdk.java.net/jdk9/client/jdk/file/a21bac70753d/src/java.desktop/share/classes/sun/print/ServiceDialog.java#l1251</a><br>
      it is enabled if we specify in testcase<br>
      <i>job.setDefaultSelection(JobAttributes.DefaultSelectionType.SELECTION);
      </i>in which case isAWT set to true.<br>
      even though selection is determined by attribute support
      [<a moz-do-not-send="true" class="moz-txt-link-freetext"
href="http://hg.openjdk.java.net/jdk9/client/jdk/file/a21bac70753d/src/java.desktop/share/classes/sun/print/ServiceDialog.java#l1320">http://hg.openjdk.java.net/jdk9/client/jdk/file/a21bac70753d/src/java.desktop/share/classes/sun/print/ServiceDialog.java#l1320</a>]<br>
      <br>
      I could not find why it is hardcoded to setEnabled(true) for
      "Selection". Do you know? mercurial history shows that line from
      jdk7 and I could not find previous history.<br>
       I think there also, we should check for "<span id="l1320">scSupported"
        to enable sheetcollate? Anyways, "Selection" option is not there
        in linux.<br>
        Please let me know your views.<br>
      </span><br>
      Regards<br>
      Prasanta<br>
    </blockquote>
    <br>
  </body>
</html>