RFR: 8283214: [macos] Screen magnifier does not show the magnified text for JcomboBox [v3]
Abhishek Kumar
abhiscxk at openjdk.org
Fri Jun 30 07:49:04 UTC 2023
On Thu, 29 Jun 2023 20:43:00 GMT, Alexey Ivanov <aivanov at openjdk.org> wrote:
>> src/java.desktop/share/classes/javax/swing/plaf/basic/BasicComboBoxUI.java line 1141:
>>
>>> 1139: return(Accessible) popup;
>>> 1140: }
>>> 1141: break;
>>
>> Why do you change indentation? To minimise the number of changed lines, please keep the existing indentation.
>
> It's a matter of style.
>
> The [old conventions](https://www.oracle.com/docs/tech/java/codeconventions.pdf)¹ suggest that `case` statements shouldn't be indented. The code followed this style.
>
> [A latest draft](https://cr.openjdk.org/~alundblad/styleguide/index-v6.html) which is often referred to explicitly states that `case` statements should be indented with four spaces and the statements inside should be be indented with additional four spaces.
>
> The updated code follows the new style. Since you're updating the code in the `switch` statement, it's fine to change the indentation… provided we agree to *follow the new style*.
>
> ¹ The [HTML version for `switch` statement](https://www.oracle.com/java/technologies/javase/codeconventions-statements.html#468) is completely *unreadable now*.
> It's a matter of style.
>
> The [old conventions](https://www.oracle.com/docs/tech/java/codeconventions.pdf)¹ suggest that `case` statements shouldn't be indented. The code followed this style.
>
> [A latest draft](https://cr.openjdk.org/~alundblad/styleguide/index-v6.html) which is often referred to explicitly states that `case` statements should be indented with four spaces and the statements inside should be be indented with additional four spaces.
>
> The updated code follows the new style. Since you're updating the code in the `switch` statement, it's fine to change the indentation… provided we agree to _follow the new style_.
>
> ¹ The [HTML version for `switch` statement](https://www.oracle.com/java/technologies/javase/codeconventions-statements.html#468) is completely _unreadable now_.
The indented code is more readable and as you pointed it is inline with new style too. So, I am ok with the current indentation if we are on same page.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/14497#discussion_r1247547737
More information about the client-libs-dev
mailing list