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

[macosx] Support automatic @2x images loading on Mac OS X

XMLWordPrintable

    • b01
    • generic
    • os_x
    • Not verified

        This issue is part of the general issue JDK-7124410 [macosx] Lion HiDPI support

        A user provides high resolution images with @2x modifier.
        The Toolkit.getImage(String filename) and Toolkit.getImage(URL url) methods should automatically load the high resolution image and show an image with best fit resolution on HiDPI display (Retina) on Mac OS X.

        For example, there are files on disk:
        - /dir/image.ext
        - /dir/image@2x.ext

        Image image = Toolkit.getDefaultToolkit().getImage("/dir/image.ext") //both images (image.ext and image@2x.ext) should be automatically loaded
        graphics2d.drawImage(image,..) // The image with necessary resolution should be drawn according to the display transform and scale

              alexsch Alexandr Scherbatiy
              art Artem Ananiev (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              10 Start watching this issue

                Created:
                Updated:
                Resolved: