Need an official way to exclude parts of the SceneGraph from CSS-Processing
hastebrot at gmail.com
Tue Jan 24 08:46:23 UTC 2017
>As Kevin notes, improving performance is a big push I want to get underway
for JDK 10.
I'd also love to see the PerformanceTracker API outside of com.sun in JDK
>If anyone is interested in exploring performance-related topics in JavaFX
I'll ping you, when I've more time to deeply think and experiment with
improvements to the PerformanceTracker.
On Tue, Jan 24, 2017 at 12:15 AM, Jonathan Giles <jonathan.giles at oracle.com>
> There are two different topics here, both of which are near and dear to my
> heart (and also make me feel like I've been doing JavaFX for way too long!).
> The specific case of TabPane doing CSS / layout on the content of all tabs
> is something captured here:
> It dates back to 2012 and I remember spending considerable amount of
> effort with my team working through this. As can be seen in some of the
> comments, there were attempts to improve performance (and they were really
> nice), but the outcome was to back it out as we could not change the
> default semantics of loading and doing all work on all tabs. The
> second-to-last comment was a proposal for some API that would specify the
> policy. I really would like to pick this back up for JDK 10, as JDK 9 is
> locked and loaded in this regard. I have retargeted this for JDK 10 just
> As Kevin notes, improving performance is a big push I want to get underway
> for JDK 10. The more general comment made in your email is - how can we get
> better performance out of our critical paths (CSS, layout, TableView, etc).
> That's something we will be actively exploring. There are a lot of ideas,
> some will yield results and some won't. I've been running into a few of
> those dead-ends myself recently as I do preliminary investigations.
> If anyone is interested in exploring performance-related topics in JavaFX,
> I've got plenty of areas to explore :-) Ping me off-list and we can discuss.
> Unfortunately, again, unless there is some critical oversight these
> discussions and investigations into performance and additional API are by
> default targeted to JDK 10 rather than JDK 9.
> -- Jonathan
> On 20/01/17 11:43 PM, Tom Schindl wrote:
>> One of the biggest problems when working with JavaFX is that if you
>> reparent a big portion of the SceneGraph is that a full CSS-Pass is
>> applied on all reparented SG-Nodes even if those nodes are currently not
>> visible (eg. because they are part of a TabPane).
>> I general I think it is ok to also applyCSS changes on currently not
>> visible nodes (eg they still have an influence on layout-bounds) but
>> there are situations like the above mentioned example of TabPane that it
>> is unnecessary overhead to apply applyCSS changes on those parts of the
>> SG until they get visible.
>> I would not mind if the CSS-Pass on JavaFX would be as performant as the
>> one from current browsers but unfortunately it isn't so I'd like to
>> discuss the possibility of a API to *temporarily* exclude portions of
>> the SG from CSS-Passes.
>> In JavaFX8 i was able to hack that in by overwriting impl_processCSS in
>> a subclass who changed to doProcessCSS who now is private so my hack
>> does not work anymore.
>> To give you an impression on what performance gains we are talking about
>> just look at the video I recorded -
More information about the openjfx-dev