Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8247370

Clean up unused printing code in awt_PrintJob.cpp

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 17
    • Component/s: client-libs
    • Labels:
    • Subcomponent:
      2d
    • Resolved In Build:
      b15

      Description

      Whilst working on https://bugs.openjdk.java.net/browse/JDK-8240654
      It was noticed that doPrintBand in awt_PrintJob.cpp is only ever called
      with a bottom up DIB. Maybe we can get rid of the code path that
      handles top-down ? it seems like it was for browser printing since
      it supplied a top-down DIB. Although it is still converted to bottom up
      for printing because a number of printer drivers did not handle top-down
      properly.

      JDK's *shared* printing code effectively creates a bottom-up DIB by
      setting a transform for the rendering. This meant it did not have to
      use up memory by making a reversed copy during printing.
      So given that PCs now have vast amounts of RAM compared to when
      this code choice was made possibly we could change that shared
      code instead and make the top-down case the norm ? Probably not but something to think about.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              prr Philip Race
              Reporter:
              prr Philip Race
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: