On Wed, 27 Apr 2022 00:00:19 GMT, Sergey Bylokhov <s...@openjdk.org> wrote:
> We don't need to push change down to the pipeline, we should push it up to > the place where we paint this ImageIcon, eventually where we call > ImageIcon.paintIcon() Why? As i shown in the test case the problem affects any ImageIcon based on the MultiResolutionImage. I'm not trying to solve the singular issue that in the Windows LaF - i am trying to eliminate the reason this problem can show up. > Then why, as described in the JBS, it worked before? Did we request different > image, or size, or did we skip scaling? Because before that change we were using different binary API to retrieve icons. This API only allows gathering 8x8 and 16x16 icons. The new API can be used for requesting icons of any size but for some files it ignores the requested size and only returns 32x32 icon. In this case we creating the multi resolution image with that icon inside and allow icon painting routine do the scaling. As i shown in my test for this bug the scaling works poorly and here i'm trying to enhance it. Can it be done in WinLAF? Yes, absolutely, but it will not solve the more generic issue. ------------- PR: https://git.openjdk.java.net/jdk/pull/7805