<Swing Dev> RFR: 6251901: BasicTextUI: installDefaults method are contrary to the documentation
Alexander Zvegintsev
azvegint at openjdk.java.net
Tue Mar 9 14:04:07 UTC 2021
On Tue, 9 Mar 2021 08:09:04 GMT, Prasanta Sadhukhan <psadhukhan at openjdk.org> wrote:
> BasicTextUI: installDefaults javadoc specifies only font, foreground and background properties are set if their current value is either null or a UIResource
> and other properties are set if the current value is null
> but in reality all properties such as font, foreground, background, caret color, selection color, selected text color, disabled text color, and border color are set if their current value is either null or a UIResource.
> Fixed the javadoc to specify the same.
src/java.desktop/share/classes/javax/swing/plaf/basic/BasicTextUI.java line 306:
> 304: * Initializes component properties, such as font, foreground,
> 305: * background, caret color, selection color, selected text color,
> 306: * disabled text color, and border color. All properties are set
This method is also affects a margin, but it is does not mentioned in the javadoc.
-------------
PR: https://git.openjdk.java.net/jdk/pull/2888
More information about the swing-dev
mailing list