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.
程序运行时,如何在文本区域内显示加载文本?目前,文本显示在 ActionPerformed 上,但我希望它在程序运行时显示。
只需将初始值传递给构造函数
TextArea textArea = new TextArea("My default string");
对于JTextArea.
JTextArea