JavaFX Toolbar overflow fixed - our first contribution

If the width of the items of a horizontal ToolBar of fixed size increases after they were added and after a layout pass has happened, the overflow button won't appear even when it would then be necessary. As layout is still performed, the wider elements are displayed but some of them are placed outside of the ToolBar and the user is not able to reach this items.

We used this first contribution to see the actual status of the project. The first thing we realized was: IntelliJ config files are useless and the project could not be opened in the IDE from the build.gradle files. And we had a look to the alternatives: eclipse, Netbeans, vim…. We did not find anything better than fixing the build.gradle file: Developing OpenJFX in a IDE 😀

Before the fix in the overflow button won’t appear.

Before the fix in the overflow button won’t appear.


We found out very fast what was the cause of this misbehavior and fixed it.

This leads to our first contribution to OpenJFX.

After the fix, you see the overflow button is present and all toolbar items can be reached if clicked on the overflow button.

After the fix, you see the overflow button is present and all toolbar items can be reached if clicked on the overflow button.

As it turns out, a long online interchange was necessary for this relative simple fix, next time will be better, I promise 😬:

https://github.com/javafxports/openjdk-jfx/pull/318

Our contribution also resulted in fix the official JDK bug:

https://bugs.openjdk.java.net/browse/JDK-8152395