<Swing Dev> [9] Review request for 8160986 Bad rendering of Swing UI controls with Metal L&F on HiDPI display
Alexandr Scherbatiy
alexandr.scherbatiy at oracle.com
Mon Aug 1 12:21:57 UTC 2016
On 7/29/2016 9:03 PM, Semyon Sadetsky wrote:
> Alexander,
>
> the slider thumb is not scaled at all.
This is a regression from the fix: JDK-8143064 Icons are not properly
rendered with Windows L&F on HiDPI display
The problem is that the
MetalIconFactory.OceanVerticalSliderThumbIcon/OceanHorizontalSliderThumbIcon.paintToImage(...)
methods do not take provided image size into account.
I have filled an issue on it: JDK-8162856 JSlider thumb is twice
smaller on HiDPI display.
Thanks,
Alexandr.
>
> --Semyon
>
>
> On 7/28/2016 7:45 PM, Alexandr Scherbatiy wrote:
>>
>> Hello,
>>
>> Could you review the updated fix:
>> http://cr.openjdk.java.net/~alexsch/8160986/webrev.02
>>
>> - html part of the test is removed
>>
>> On 7/27/2016 8:11 PM, Phil Race wrote:
>>> > D3D on: 20468 [1] -> 21486 [2] performance increasing: 5%
>>> If I recall correctly, the SwingMark summary score is actually
>>> the run time .. so an increasing number is actually a decrease in
>>> peformance.
>> Sorry. The performance is definitely is decreased after the fix.
>>
>> Thanks,
>> Alexandr.
>>>
>>> Still, the improvement in the visual results is worth it to me.
>>>
>>> The test is still odd and I am not sure what the intent is.
>>> If its an applet test then the @test tag should be on the .html file.
>>> The @bug tag in the Java file is 8040279 which is unrelated to this
>>> issue.
>>> But it looks like its just a way to display some instructions to run
>>> SwingSet2.
>>> I am not sure that it is at all worth adding something like that as
>>> a test.
>>>
>>> -phil
>>>
>>>
>>>
>>> On 07/27/2016 09:49 AM, Alexandr Scherbatiy wrote:
>>>> Hello,
>>>>
>>>> Could you review the updated fix:
>>>> http://cr.openjdk.java.net/~alexsch/8160986/webrev.01
>>>>
>>>> - horizontal scroll bars are updated
>>>> - the test name is updated
>>>> - the instruction to test both vertical and horizontal scroll bars
>>>> are added to the test
>>>>
>>>> I run the SwingMark for the JRadioButton which is painted with
>>>> selected/deselected and enabled states
>>>> and JScrollPane which shows vertical and horizontal scroll bars in
>>>> turn.
>>>> Each component was repainted 2002 times and the test was repeated
>>>> 20 times.
>>>>
>>>> The results below show the SwingMark tests score for D3D on/off in
>>>> format:
>>>> test score for the component before the fix [link to the results]
>>>> -> test score for the component after the fix (using ovals or
>>>> polygons) [link to the results] performance increasing in percents.
>>>>
>>>> JRadioButton
>>>> D3D on: 20468 [1] -> 21486 [2] performance increasing: 5%
>>>> D3D off: 20299 [3] -> 21075 [4] performance increasing: 4%
>>>>
>>>> JScrollPane
>>>> D3D on: 56184 [5] -> 57742 [6] performance increasing: 3%
>>>> D3D off: 51758 [7] -> 52987 [8] performance increasing: 3%
>>>>
>>>> If it is necessary, polygons which draw triangles can be replaced
>>>> by Line2D.Float().
>>>>
>>>> Thanks,
>>>> Alexandr.
>>>>
>>>> [1]
>>>> http://cr.openjdk.java.net/~alexsch/8160986/swingmark/00/radio-button-d3d-on-base.txt
>>>> [2]
>>>> http://cr.openjdk.java.net/~alexsch/8160986/swingmark/00/radio-button-d3d-on-oval.txt
>>>> [3]
>>>> http://cr.openjdk.java.net/~alexsch/8160986/swingmark/00/radio-button-d3d-off-base.txt
>>>> [4]
>>>> http://cr.openjdk.java.net/~alexsch/8160986/swingmark/00/radio-button-d3d-off-oval.txt
>>>>
>>>> [5]
>>>> http://cr.openjdk.java.net/~alexsch/8160986/swingmark/00/scroll-pane-d3d-on-base.txt
>>>> [6]
>>>> http://cr.openjdk.java.net/~alexsch/8160986/swingmark/00/scroll-pane-d3d-on-polygon.txt
>>>> [7]
>>>> http://cr.openjdk.java.net/~alexsch/8160986/swingmark/00/scroll-pane-d3d-off-base.txt
>>>> [8]
>>>> http://cr.openjdk.java.net/~alexsch/8160986/swingmark/00/scroll-pane-d3d-off-polygon.txt
>>>>
>>>> On 7/27/2016 3:33 PM, Philip Race wrote:
>>>>> BTW I meant to point out (but forgot) that I want us
>>>>> to stop using bug ids as test names. When you stare
>>>>> at a list of tests in a directory I'd like to see meaningful names.
>>>>>
>>>>> I don't know what the intention was with the tests here but
>>>>> any new test should be so named ..
>>>>>
>>>>> -phil.
>>>>>
>>>>> On 7/26/16, 11:57 PM, Yuri Nesterenko wrote:
>>>>>> You mean probably that the first test would not compile since
>>>>>> it is "public class bug8160986 " in bug8031573.java ?:-)
>>>>>>
>>>>>> -yan
>>>>>>
>>>>>> On 07/27/2016 12:08 AM, Phil Race wrote:
>>>>>>> Since I noticed it right away, I am sure lots of others will
>>>>>>> soon enough.
>>>>>>>
>>>>>>> -phil.
>>>>>>>
>>>>>>> On 07/25/2016 02:19 PM, Sergey Bylokhov wrote:
>>>>>>>> On 07.07.16 22:00, Phil Race wrote:
>>>>>>>>> the screenshot here bears that out .. ie left/right do not
>>>>>>>>> look to be
>>>>>>>>> any better.
>>>>>>>>>
>>>>>>>>> http://cr.openjdk.java.net/~alexsch/8160986/screenshots/scrollpane-00.png
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>> Since it was missed by the author, I am not sure that it will
>>>>>>>> be found
>>>>>>>> by the tester who will run the test.
>>>>>>>>
>>>>>>>>> On 07/07/2016 11:55 AM, Alexandr Scherbatiy wrote:
>>>>>>>>>>
>>>>>>>>>> Hello,
>>>>>>>>>>
>>>>>>>>>> Could you review the fix:
>>>>>>>>>> bug: https://bugs.openjdk.java.net/browse/JDK-8160986
>>>>>>>>>> webrev: http://cr.openjdk.java.net/~alexsch/8160986/webrev.00
>>>>>>>>>>
>>>>>>>>>> The proposed fix changes icon shapes drawn by lines to
>>>>>>>>>> ovals and
>>>>>>>>>> polygons for JRadioButton, JComboBox and JScrollBar
>>>>>>>>>> components for the
>>>>>>>>>> Metal L&F.
>>>>>>>>>>
>>>>>>>>>> The screenshots [1] give a hint how UI controls look before
>>>>>>>>>> and
>>>>>>>>>> after the fix.
>>>>>>>>>>
>>>>>>>>>> [1] http://cr.openjdk.java.net/~alexsch/8160986/screenshots
>>>>>>>>>>
>>>>>>>>>> Thanks,
>>>>>>>>>> Alexandr.
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>
>>>>
>>>
>>
>
More information about the swing-dev
mailing list