Anybody know if there is an easy way to limit the allowed characters for a JTextArea. I.e. similar to JTextField using MaskFormatter.
Specifically I want to limit th
Implement a javax.swing.text.DocumentFilter to remove inappropriate characters. Set that on your favourite AbstractDocument and construct you JTextArea with that.
javax.swing.text.DocumentFilter
AbstractDocument
JTextArea