50,530
社区成员
发帖
与我相关
我的任务
分享
public void insertString(int offset, String str, AttributeSet att)
throws BadLocationException {
if (getLength() + str.length() > maxLength) {
Toolkit.getDefaultToolkit().beep();
} else {
super.insertString(offset, str, att);
}
}