Uploaded image for project: 'FOP'
  1. FOP
  2. FOP-2927

Windows HiDPI: pixelated preview window

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Critical
    • Resolution: Unresolved
    • 1.0, 2.4
    • None
    • renderer/awt
    • None

    Description

      If you scale your Windows display (All settings > System > Display) to >100% the AWT-Renderer renders a pixelated view. Please see my attachments.

      How to reproduce?

      • In Windows (7-10) go to
        All settings > System > Display
        and set e.g. 150% for the "size of text, apps and other items"
      • extract the FOP archive
      • open a shell in fop-2.4\fop
      • run the command: fop.bat examples\fo\basic\fonts.fo -awt
      • the opening view is pixelated

      How to fix?

      Windows-Java returns a pre-scaled Graphics2D object. I guess this Stackoverflow question can help:
      https://stackoverflow.com/questions/43057457/jdk-9-high-dpi-disable-for-specific-panel

      final Graphics2D g = (Graphics2D) graphics;
      final AffineTransform t = g.getTransform();
      t.setToScale(1, 1);
      g.setTransform(t);
      

      But where is the right place (class) for this fix?

       

      Thank you

      Eric

      Attachments

        1. Windows scale 150.png
          100 kB
          Eric Kraußer
        2. Windows scale 100.png
          83 kB
          Eric Kraußer

        Activity

          People

            Unassigned Unassigned
            eric_8_1 Eric Kraußer
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: