Force immediate paint in JavaFX

前端 未结 3 425
耶瑟儿~
耶瑟儿~ 2021-01-12 10:13

Is there a way to force a JavaFX app to repaint itself before proceeding? Similar to a Swing Panel\'s paint(Graphic g) method (I might be getting the keywords wrong there).<

3条回答
  •  孤街浪徒
    2021-01-12 10:38

    This won't be the most helpful answer as I have toyed around with JavaFX for all of half a day, but wouldn't you use Timelines, Keyframes, and binding to accomplish your repaints instead of calling them explicitly like you have described?

    See this tutorial for an example.

提交回复
热议问题