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.
如何在 Jeditorpane 中动态生成对象?
例如:当我单击“提交”按钮时,它用于动态创建编辑器窗格对象,以便我可以从编辑器窗格获取值或使用对象名称将值设置到编辑器窗格。
谢谢
创建JFrame 作为局部变量,将JEditorPane放在JScrollpane中
将ActionListener添加到JButton
定义 HTMLEditorKit
在ActionListener中定义"objects dynamically in Jeditorpane"
"objects dynamically in Jeditorpane"