🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.swing
Article #1766

Re: how to set tab button to move focus between components

#1766
From: John McGrath [TeamB]
Date: Fri, 18 Jul 2003 05:31
19 lines
1445 bytes
On 7/17/2003 at 3:18:23 PM, Nechama Shuchatowitz wrote:

> How would I set the tab button to move the focus from one component
> to the next?

Assuming you mean the tab *key*, it should do that by default.

> Also, how would I set a JButton to be 'pressed' when the enter button
> is pressed?

Bind the Enter key.  The JDK docs cover the Key Binding mechanism.  You
can also find a copy here:

   http://java.sun.com/j2se/1.4.2/docs/api/index.html

-- 
Regards,

John McGrath  [TeamB]
Technical Details
Message-ID: <3f17864f$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-03!sn-xit-06!sn-xit-09!supernews.com!newshosting.com!news-xfer1.atl.newshosting.com!newsfeed.wirehub.nl!news.kweb.on.ca!newsgroups.borland.com!not-for-mail
References: <3f16f5de@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 111d45,acbd4777951a7e2c
X-Google-Attributes: gid111d45,public
X-Google-ArrivalTime: 2003-07-17 22:36:02 PST
From: "John McGrath  [TeamB]" <ng-b@jpmcgrath.net>
Subject: Re: how to set tab button to move focus between components
Newsgroups: borland.public.jbuilder.java.swing
References: <3f16f5de@newsgroups.borland.com>
User-Agent: XanaNews/1.15.3.1
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-15
NNTP-Posting-Host: 151.197.210.86
Message-ID: <3f17864f$1@newsgroups.borland.com>
Date: 17 Jul 2003 22:31:59 -0700
X-Trace: newsgroups.borland.com 1058506319 151.197.210.86 (17 Jul 2003 22:31:59 -0700)
Lines: 19
X-Authenticated-User: jpmcgrath
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-03!sn-xit-06!sn-xit-09!supernews.com!newshosting.com!news-xfer1.atl.newshosting.com!newsfeed.wirehub.nl!news.kweb.on.ca!newsgroups.borland.com!not-for-mail