RFR: 8218474: JComboBox display issue with GTKLookAndFeel [v2]
Abhishek Kumar
abhiscxk at openjdk.org
Tue Jan 3 04:48:51 UTC 2023
On Tue, 3 Jan 2023 01:21:07 GMT, Sergey Bylokhov <serb at openjdk.org> wrote:
>> Abhishek Kumar has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains four additional commits since the last revision:
>>
>> - Review comment update
>> - Merge
>> - Merge
>> - Combobox componnet rendering fix
>
> src/java.desktop/share/classes/javax/swing/plaf/synth/SynthComboBoxUI.java line 372:
>
>> 370: arrowButton.getPreferredSize().width;
>> 371: //adjust the size based on the button width
>> 372: size.height += insets.top + insets.bottom + arrowInsets.top
>
> Are you sure that the arrow insets should be applied on top of the component's insets, probably the maximum of both should be selected?
For combobox text to render correctly arrow inset need to be applied otherwise the combobox editor shows "..." even for a smaller text.
Since component inset's return (0, 0, 0, 0) in GTK and Nimbus LAF, didn't take the maximum of both into consideration.
-------------
PR: https://git.openjdk.org/jdk/pull/11555
More information about the client-libs-dev
mailing list