Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
在 Swing 中,可以将动作连接到按钮,并且按钮反映动作的参数,如图标、启用、文本等。
ControlsFX' 也可以做到这一点Action吗?
Action
如果是,那怎么办?
对于现有按钮,您可以使用ActionUtils.configureButton(action, button).
ActionUtils.configureButton(action, button)
要创建绑定到操作的按钮,请使用ActionUtils.createButton(action)
ActionUtils.createButton(action)