...
>It is the insert caret.
Your comments do not make much sense to me.
There is an applet here that will pop a dialog with a
JTextField and JTextArea (click the 'Input' button).
<http://www.physci.org/test/resize/>
The 'insert caret' (as I understand it) will only show in
the text field/area that currently has focus, in either the
Metal or System (Win) PLAFs.
To hide the insert caret even when it is in a particular
text widget, just set the widget uneditable or disabled
(see dropdown on main applet GUI).

Signature
Andrew Thompson
http://www.physci.org/
Roy - 04 Jan 2008 05:12 GMT
> ..
>
[quoted text clipped - 18 lines]
>
> Message posted viahttp://www.javakb.com
Thanks a lot. I happened to setFocusable(false) for all other
components. So the JTextField is the only component that always has
focus. That is why the insert caret is always blinking.
Anway, I was told by a friend that a simple way to hide the caret in
this situation is to do the following:
MyTextField.getCaret().setVisible(false);
Thanks again.
Roy
Mark Space - 04 Jan 2008 19:27 GMT
> MyTextField.getCaret().setVisible(false);
I was going to suggest the same thing Andrew did. I didn't know about
this method, good find, thanks!