+1 A full-featured API to enable rich text and syntax highlighting in editors is *very* much needed. All the attempts I have seen at creating such editors with JavaFX are basically “fudges”.
I have never seen HTMLEditor used in a real-world application. > On 26 Nov 2017, at 10:40, jav...@use.startmail.com wrote: > > Hi, This is a question about the future of Text under Javafx. > > Very briefly, Swing provided access to everything a dev could need in order > to write a rich text editor from scratch. LineBreakMeasurers and HitTesting > and everything. > > In JavaFX these things are not directly available to the dev and anyway, to > the extent that they are, they cannot be used to write a rich text editor.. > > There are many classes needed involving the measuring of glyphs and text > lines etc etc etc which would be needed for anyone who wanted to write their > own rich text editor. They exist, but are under sun.com and given the > modularization of Java 9 are truly inaccessible to developers. > > I am aware of the existing Javafx controls. I am also aware of the efforts > available at GitHub and elsewhere to create a rich text editor and all of > them without exception are handicapped by this same lack of API. > > I am also aware of HTMLEditor in JavaFX but that 1) commits the dev to > WebRenderer and 2) still doesn't provide access to the needed classes and > methods. It's not sufficient to suppose that HTML 5 or whatever follows is > the answer to all text layout challenges. > > Formerly, Swing had all these missing features available as API and many good > text editors were created using those APIs. > > For the sake of future planning, we really need to know- is there any > recognition within Oracle that this is something which has to be addressed? > Is it on any hypothetical roadmap? Or is HTMLEditor as much as JavaFX is > going to provide ? > > Thank you.