Article View: borland.public.jbuilder.java.swing
Article #711Re: Cursor won't display in components in a JWindow
From: John McGrath [TeamB]
Date: Thu, 30 Dec 2004 06:11
Date: Thu, 30 Dec 2004 06:11
24 lines
2025 bytes
2025 bytes
On 12/28/2004 at 11:09:16 AM, GUI-Majician wrote:
> I have some input fields, like JTextField in a JPanel on a JWindow but I
> can't get the cursor to show up in the text components. These components
> are not custom but regular Swing, so is the JWindow. The components do
> receive focus and you can type but no cursor!
It sounds like the Window has no owner, or its owner is not visible. If
that is the case, it cannot receive the focus. For more information, see
the JavaDocs for the Window.isFocusableWindow() method.
If it makes sense for your window to have an owner Frame (or Dialog), then
make sure you specify it in the constructor. If not, then consider using
a Frame instead of a Window. You can make the Frame undecorated to
eliminate the title bar.
--
Regards,
John McGrath [TeamB]
---------------------------------------------------
Before sending me e-mail, please read:
http://www.JPMcGrath.net/newsgroups/e-mail.html
Technical Details
Message-ID:
<xn0drm3bc98r6oq001@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news.glorb.com!transit.nntp.hccnet.nl!transit1.nntp.hccnet.nl!border2.nntp.ams.giganews.com!border1.nntp.ams.giganews.com!nntp.giganews.com!pe2.news.blueyonder.co.uk!blueyonder!news-peer-test!btnet!newsfeed.bt.es!caladan.landsraad.net!newsgroups.borland.com!not-for-mailReferences:
<41d18515$1@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 111d45,9940f1591cc93047 X-Google-Attributes: gid111d45,public X-Google-Language: ENGLISH,ASCII-7-bit From: "John McGrath [TeamB]" <ng-b@JPMcGrath.net> Subject: Re: Cursor won't display in components in a JWindow Newsgroups: borland.public.jbuilder.java.swing References: <41d18515$1@newsgroups.borland.com> User-Agent: XanaNews/1.16.5.2 Message-ID: <xn0drm3bc98r6oq001@newsgroups.borland.com> X-Ref: newsgroups.borland.com ~XNS:000000CD MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 NNTP-Posting-Host: 141.158.234.226 Date: 29 Dec 2004 22:11:37 -0800 X-Trace: newsgroups.borland.com 1104387097 141.158.234.226 (29 Dec 2004 22:11:37 -0800) Lines: 24 X-Authenticated-User: jpmcgrath Path: arc1-ca.pugleaf.net!g2news1.google.com!news3.google.com!news.glorb.com!transit.nntp.hccnet.nl!transit1.nntp.hccnet.nl!border2.nntp.ams.giganews.com!border1.nntp.ams.giganews.com!nntp.giganews.com!pe2.news.blueyonder.co.uk!blueyonder!news-peer-test!btnet!newsfeed.bt.es!caladan.landsraad.net!newsgroups.borland.com!not-for-mail