如何在JTextArea中包装文本 [英] How to wrap text in a JTextArea
本文介绍了如何在JTextArea中包装文本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在Java中有一个JTextArea。当我在其中放置大量文本时,文本区域提供水平滚动。
I have a JTextArea in Java. When I place a large amount of text in it, the text area provides horizontal scrolling.
如何使文本区域换行?
推荐答案
使用 JTextArea #setLineWrap
方法。 Swing JTextArea $中也说明了这一点。 c $ c>教程
这篇关于如何在JTextArea中包装文本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文