Rich Text Support

Kevin Rushforth kevin.rushforth at oracle.com
Fri Oct 5 20:32:25 UTC 2018


Note that I did say "at least at first" when I was agreeing that it 
should likely not be part of the core. Developing a RichText control is 
going to be a big task that will likely take a bit of experimenting to 
get everything right. Doing that externally would allow for more rapid 
prototyping and testing before committing to a core API. If it becomes 
something that is generally considered useful, and fits well with the 
other controls, then I don't necessarily see a problem getting it into 
the core (although it would need to go through an feature review just 
like any new API). That was what we did for Alert and Spinner when they 
were first implemented; both needed a fair bit of additional work before 
bringing it into javafx.controls, but it was heavily leveraged by the 
work done in ControlsFX.

Btw, I might feel the same way about, say, DatePicker if we were 
developing it now. However, I do think that almost all of the current 
set fit within what I would expect a UI toolkit to provide as a default 
set of controls.

Johan might have a somewhat different take on this, so it would be good 
to get his thoughts.

-- Kevin


On 10/5/2018 12:59 PM, John-Val Rose wrote:
> Kevin,
>
> I am somewhat curious as to this idea that new JavaFX controls should not be part of the core toolkit.
>
> Why do feel this way?
>
> And I guess it begs the question: Why have *any* controls in the core of JavaFX at all?
>
> Graciously,
>
> John-Val Rose
> Rosethorn Technology
>
>> On 5 Oct 2018, at 23:34, Kevin Rushforth <kevin.rushforth at oracle.com> wrote:
>>
>> I agree that new controls, especially a RichText control, should very likely not be part of the core -- at least not at first. Somewhere like ControlsFX might be a great place to develop it. What we need to do is identify the missing pieces that prevent it from being implemented as an external control. The text measurement API is one such missing piece, but I'll bet there are others.
>>
>> -- Kevin
>>
>>
>>> On 10/3/2018 11:08 AM, Tom Schindl wrote:
>>> Hi,
>>>
>>> I fully agree and I don't think such a control should be part of the
>>> OpenJFX but should live in an other library.
>>>
>>> /me thinks OpenJFX should not get *ANY* new controls (I would even argue
>>> that the current controls should be split out) but provide the core APIs
>>> needed to implement them.
>>>
>>> Tom
>>>
>>>> On 03.10.18 19:39, Phil Race wrote:
>>>>
>>>>> On 10/03/2018 05:50 AM, Pedro Duque Vieira wrote:
>>>>> I think to start, probably a class like Swing's FontMetrics would be good
>>>>> to have? Before Java 9 there was one but it was private implementation.
>>>>> Just to have the basic API that would allow to build rich text editing
>>>>> support more easily, sorted out..
>>>>> This is also, generally, needed for calculating how to lay out text.
>>>> I agree, and maybe I should aim to finally implement this in 12 :
>>>> https://bugs.openjdk.java.net/browse/JDK-8090775: Need font/text
>>>> measurement API
>>>>
>>>> -phil.



More information about the openjfx-discuss mailing list