x-dev@openjdk.org
Subject: Re: RichTextArea: RichTextArea doesn't have a setText method, but
CodeArea does
To be honest, I think this will create problems when working with the
RichTextArea API.
Why? Because every developer will intuitively look for setText. For example,
TextArea
—https://
It would be easy enough to add one as a convenience method, if it was
deemed useful enough. Andy can comment further.
-- Kevin
On 5/1/2025 10:41 AM, PavelTurk wrote:
To be honest, I think this will create problems when working with the
RichTextArea API.
Why? Because every developer will intu
To be honest, I think this will create problems when working with the
RichTextArea API.
Why? Because every developer will intuitively look for setText. For example,
TextArea
—https://docs.oracle.com/javase/8/javafx/api/javafx/scene/control/TextArea.html
—
has setText. CodeArea has setText. But
Note that there is an easy way to set plain text if you are using a
writable model:
rta.clear();
rta.appendText(String text);
-- Kevin
On 5/1/2025 7:55 AM, Andy Goryachev wrote:
Intentionally: the CodeArea model contains plain text, while in the
RichTextArea the content depends on the mode
Intentionally: the CodeArea model contains plain text, while in the
RichTextArea the content depends on the model. It may not contain anything and
be generated on the fly.
-andy
From: openjfx-dev on behalf of PavelTurk
Date: Thursday, May 1, 2025 at 05:40
To: openjfx-dev@openjdk.org
Sub