[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openjdk-macosx-port-dev
Subject:    Re: Aqua Icons support on HiDPI displays.
From:       Hendrik Schreiber <hs () tagtraum ! com>
Date:       2013-10-23 15:43:07
Message-ID: 43F4F10A-F8F6-4056-989B-D666B13344BA () tagtraum ! com
[Download RAW message or body]


On Oct 23, 2013, at 5:38 PM, Alexander Scherbatiy wrote:
> > 
> > may I ask through which API you intend to make the icons available?
> 
> There is a way to load system images and icons on MacOS X in Java by using: \
> Toolkit.getDefaultToolkit().getImage("NSImage://NSImageName") method: \
> https://developer.apple.com/library/mac/documentation/java/conceptual/java14development/04-JavaUIToolkits/JavaUIToolkits.html
>  This method calls [NSImage imageNamed: "NSImageName"] and we are going to reuse it \
> for the system icons loading. 
> > Also, will there be a way to create custom HiDPI images/icons?
> > If so, how?
> 
> There is the fix that has been recently sent to review: \
> http://mail.openjdk.java.net/pipermail/awt-dev/2013-October/006133.html A user \
> needs to override the getScaledInstance(width, height, hints)  method in Image \
> class and returns images with necessary resolution according to the given width and \
> height.  Images with @2x postfix should be automatically loaded into the \
> ToolkitImage on MacOS X.

Very nice!
Any idea whether this will be backported to Java7 (assuming this is for 8)? 

-hendrik=


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic