In a custom TabBarButton / paintButton, I’m doing this:
This fails drawing the rectangle for all but first button.
but if I do :
g.fillRect(5, 0, getWidth() - 10, getHeight());
It’s working perfectly.
I think the former is easier to understand than the later, but I don’t understand why it fails.
Also, while I’m not sure, I have the feeling the former slows the process start up (the window takes maybe 2 or 3 more seconds to display).