RFR: 8283214: [macos] Screen magnifier does not show the magnified text for JcomboBox [v5]

Alexey Ivanov aivanov at openjdk.org
Thu Jul 6 11:58:10 UTC 2023


On Thu, 6 Jul 2023 11:15:31 GMT, Abhishek Kumar <abhiscxk at openjdk.org> wrote:

>>> > But it doesn't look right to me that the drop-down button is the main component of the combo box if it's non-editable. The combo box should handle the accessibility request itself in this case. It still uses the same renderer which can't be put into editable state. The renderer is never added into containment hierarchy.
>>> 
>>> In case of non-editable combobox there is no editor as such and arrowButton is the main component. When native side request a11y information, accessible interface for combo button is returned (as only two accessible component are present. One is arrow button and other is popup). Subsequent accessible APIs are invoked for combo button to get accessible name.
>> 
>> Do you think it is correct?
>> 
>> I admit refactoring / rewriting accessibility implementation for `JComboBox` is out of scope in this bug. Yet the current way doesn't feel right.
>
>> Do you think it is correct?
>>
>> I admit refactoring / rewriting accessibility implementation for JComboBox is out of scope in this bug. Yet the current way doesn't feel right.
> 
> I think so. 
> If I am not wrong the non-editable JComboBox doesn't have any editor, so the arrowButton width and height is equal to the combobox width and height. This results in arrowbutton rendering for entire display area of combobox. Due to this we are getting the accessible interface invoked for combobox button.

Yes, non-editable combo box doesn't have the editor. Yet the arrowButton is not what displays the text. It is for this reason that I think it is wrong that the button becomes the main component which handles accessibility for combo box if it's not editable. It is not the button that displays the text.

Setting accessible name in `doRendererPaint` doesn't feel right either.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/14497#discussion_r1254331218



More information about the client-libs-dev mailing list