Switch to full style
Java2 codes,problems ,discussions and solutions are here
Post a reply

Finding The Blinking Cursor

Fri Oct 24, 2008 5:32 pm

I've written an application that contains several editable JTextAreas
and JTextFields. It also has a menu bar. I've written code to copy
and paste with menu bar commands. I'm having problems with the paste.
The problem is getting the application to choose the correct text
element in which to insert the clipboard text. I want it to go to the
text field or area where I have clicked the mouse and inserted a
visible cursor. Normal windows text editing behavior.

What I know wont work:
- Choosing the textarea with focus. Focus goes to the menubar by
clicking edit/paste.
- Locating the text caret, getCaret(). All the text elements have
one, I want the cursor, not the caret.

I'm sure there must be a simple api, but I can't find it. Any ideas
would be appreciated



Post a reply
  Related Posts  to : Finding The Blinking Cursor
 Finding a Substring Within a String in php     -  
 finding the largest integer     -  
 Change cursor to help     -  
 JavaScript Cursor     -  
 Change cursor to wait     -  
 custom cursor in javascript     -  
 Change cursor to crosshair     -  
 Change cursor to move     -  
 Change the mouse cursor to hand pointer     -