On Thu, 19 Dec 2019 14:01:08 GMT, Jeanette Winzenburg <faste...@openjdk.org> wrote:
>> Yes, that doesn't make a lot of sense. It's probably an artifact because I >> expected a different API do unregister the listener. I'm gonna change it >> back! > > just thinking aloud: actually, it's rather whacky that the indicator > (mis-)uses the skin's multiplePropertyListener - it's api isn't meant for > frequent register/unregisters (the unregisters is quite a heavy measure). > Maybe it should have its own? Or the other way round: skin listening to the > property and indicator having a method to update based on font which is > invoked by skin's listener? Yes, that would be reasonable. I would rewrite the fix, add an method "updateFont" to the skin, which also updates the DeterminationIndicator. When I look into the code, I'm a little bit confused. The fontListeners doesn't get called without a font-change. In this case, the variable doneTextWidth and doneTextHeight never get's initialized. Do I miss something or is the current code wrong? ------------- PR: https://git.openjdk.java.net/jfx/pull/71