2 ms·You're supposed to do all your graphics-related stuff in a single thread. Swing and JavaFX aren't thread-safe.by jfim 14y agoYou're supposed to do all your graphics-related stuff in a single thread. Swing and JavaFX aren't thread-safe.