对于 TextArea,getMaxSize 真正返回什么?
TextArea 类有一个名为 getMaxSize()
的方法,该方法返回一个 int
值。我不明白它到底表达了什么?是宽度(列)还是高度(行)还是其他什么?
还有 setMaxSize(int maxSize)
方法。
那么使用 TextArea 时大小意味着什么?
The TextArea class has a method called getMaxSize()
which returns an int
value. I do not understand what does it really express ? Is it the width ( columns ) or the height ( rows ) or something else ?
There is also the setMaxSize(int maxSize)
method.
So what does the size mean when working with TextArea ?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

setMaxSize
用于设置TextArea
的最大大小。如果您传递 20 意味着TextArea
上只允许使用 20 个字符。getMaxSize
返回TextArea
的最大大小。这意味着它的返回值是 20。不要与列、行或其他东西混淆。有关详细信息,请参阅 TextArea javadoc。setMaxSize
for set the maximum size of theTextArea
. If you pass 20 means only 20 characters allow on theTextArea
. AndgetMaxSize
returns the maximum size ofTextArea
. That means its return 20. Don't confuse with column or row or somethings else. For more info, look at TextArea javadoc.