[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openjdk-2d-dev
Subject:    Re: RFR: JDK-6229853: BasicTextAreaUI:create incompletely documents the possible returned View types
From:       Alexey Ivanov <aivanov () openjdk ! org>
Date:       2022-09-28 12:32:26
Message-ID: 6lI70mIUrPlclGDoFcSYkYasrOBlCxX4irw_4rQrWjY=.a1d32e29-b521-4ea9-8ebb-42eca6c04d4a () github ! com
[Download RAW message or body]

On Wed, 28 Sep 2022 12:11:31 GMT, Prasanta Sadhukhan <psadhukhan@openjdk.org> wrote:

> > API specification says about BasicTextAreaUI.create "Returns a WrappedPlainView \
> > or PlainView".  But for \
> > [bidi](https://github.com/openjdk/jdk/blob/d14e96d9701dae951aa365029f58afb6687a646 \
> > a/src/java.desktop/share/classes/javax/swing/plaf/basic/BasicTextAreaUI.java#L168) \
> > text, this method returns BoxView and other views , so the documentation needs to \
> > be updated.
> 
> Prasanta Sadhukhan has updated the pull request incrementally with one additional \
> commit since the last revision: 
> javadoc fix

Looks good if our decision is not document the types of views returned.

src/java.desktop/share/classes/javax/swing/plaf/basic/BasicTextFieldUI.java line 86:

> 84: 
> 85:     /**
> 86:      * Creates a view based on an element.

Should we use the wording from `BasicTextUI` for consistency?

Suggestion:

     * Creates a view for an element.


The description in [`ViewFactory.create`](https://docs.oracle.com/en/java/javase/17/do \
cs/api/java.desktop/javax/swing/text/ViewFactory.html#create(javax.swing.text.Element)) \
is more detailed, a short sentence as above is enough for `TextUI`.

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

Marked as reviewed by aivanov (Reviewer).

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


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic