<AWT Dev> RFR: 8216358: [accessibility] [macos] The focus is invisible when tab to "Image Radio Buttons" and "Image CheckBoxes" [v2]
kizune at openjdk.java.net
Thu Feb 4 16:31:43 UTC 2021
On Wed, 3 Feb 2021 23:52:24 GMT, Sergey Bylokhov <serb at openjdk.org> wrote:
>> Alexander Zuev has updated the pull request incrementally with one additional commit since the last revision:
>> Test simplification.
> src/java.desktop/macosx/classes/com/apple/laf/AquaButtonLabeledUI.java line 178:
>> 176: }
>> 178: altIcon.paintIcon(c, g, iconRect.x - offset, iconRect.y - offset);
> Is it possible that due to offset on the left/top we will draw the icon outside the button bounds on the right/bottom?
No. I am substracting the offset to keep drawn image inside the checkbox/radiobutton icon drawing box which is by default size of the icon+4 in width and height, hence i am shifting it up and left to avoid drawing outside the icon box. If size of the image button is artificially limited to the value less or equal of the icon size then halo will be clipped to stay within the borders of the component. In any case we will not overdraw outside of the component.
More information about the awt-dev