I’m using java, and I’m trying to make a JTextArea that is non-editable but still has the caret in the field. In other words, a Text Area that does not display characters typed by the user, but still has the blinking caret (i.e. focus).
I honestly stumped on this problem. I’ve tried mucking around with setEditable, but theres no way to keep the caret. I’ve also tried deleting the character the user enters as soon as they type it, but i can’t stop it flashing on the screen.
I think the following will help you:
or