RFR: 8300891: Deprecate for removal javax.swing.plaf.synth.SynthLookAndFeel.load(URL url) [v3]

Prasanta Sadhukhan psadhukhan at openjdk.org
Tue Jan 31 03:37:57 UTC 2023


On Mon, 30 Jan 2023 18:15:05 GMT, Phil Race <prr at openjdk.org> wrote:

>> src/java.desktop/share/classes/javax/swing/plaf/synth/SynthLookAndFeel.java line 637:
>> 
>>> 635:      * @since 1.6
>>> 636:      * @deprecated Use {@link load(InputStream, Class)} or
>>> 637:      * {@link setStyleFactory} instead
>> 
>> The link to setStyleFactory was used like "{@link #setStyleFactory}" earlier
>> https://github.com/openjdk/jdk/blob/master/src/java.desktop/share/classes/javax/swing/plaf/synth/SynthLookAndFeel.java#L77
>> 
>> shouldn't we keep it same?
>
> where was this ? And why ? This works just fine.

I guess there's different ways but AFAIS, java.desktop javadocs use 
"@link xxx to link to a class
and "@link #xxx" to link to a field, constant or method in a class

for example, in SYnthLookAndFeel class only, we have this 
_{@link #load} method, or provide your own {@link SynthStyleFactory}
  to {@link #setStyleFactory}_

ANother example 

java/awt/Color.java:     * Throws an {@link IllegalArgumentException} if the value is out of
java/awt/Color.java:     * {@link ColorModel}.
java/awt/Color.java:     * format used by the method {@link #getRGB() getRGB}.


and here setStyleFactory is a method, so I asked...

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

PR: https://git.openjdk.org/jdk/pull/12175



More information about the client-libs-dev mailing list