Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #20040

Is there a delay in select() of JTextComponent?

Path csiph.com!usenet.pasdenom.info!news.albasani.net!.POSTED!not-for-mail
From Jan Burse <janburse@fastmail.fm>
Newsgroups comp.lang.java.programmer
Subject Is there a delay in select() of JTextComponent?
Date Sun, 02 Dec 2012 18:29:41 +0100
Organization albasani.net
Lines 23
Message-ID <k9g365$t0b$1@news.albasani.net> (permalink)
Mime-Version 1.0
Content-Type text/plain; charset=ISO-8859-15; format=flowed
Content-Transfer-Encoding 7bit
X-Trace news.albasani.net yq9Y7+WNGpGs3pNQ0zIeVx3OySL0dYZMVfxHdczcBOTYSaZEFVZGqJuPSQq6Nf+YhuakEoU0QQq698ie8WK+0Q==
NNTP-Posting-Date Sun, 2 Dec 2012 17:29:41 +0000 (UTC)
Injection-Info news.albasani.net; logging-data="cJPNdCqM9MvhCszJZ2BT8JBxgl7PP4AEzc66Y7RdcR3YvoRBLiPivUh5DfC9gzdzL7SueWvQ0ZIs4lAz1xg3P41PHIp9a7zkf78tePZMw7dGCCZ5FmLgLXZIlt7yHsNI"; mail-complaints-to="abuse@albasani.net"
User-Agent Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/17.0 Firefox/17.0 SeaMonkey/2.14
Cancel-Lock sha1:7i+rvXpM9Ak7we4OJTrmsEW9z+M=
Xref csiph.com comp.lang.java.programmer:20040

Show key headers only | View raw


Dear All,

I have a very simple application. There is a menu item
with a F2 accelerator. The action of the menu item will
advance the selected text region of the underlying text
component.

When I press and hold down F2, I will get multiple actions
at the same rate as for example when pressing and holding
down the arrow down key. But somehow the for my F2, the
GUI is not able to keep up. But the arrow down key
can do so.

How can I prevent that my F2 actions get stacked up because
the GUI is not responding fast enough? It seems that the
GUI is fast enough, since everything else works fine, such
as arrow down or scroll bar. But somehow the select() seems
to be slow.

Bye

(*)
http://docs.oracle.com/javase/1.4.2/docs/api/javax/swing/text/JTextComponent.html#select%28int,%20int%29

Back to comp.lang.java.programmer | Previous | NextNext in thread | Find similar | Unroll thread


Thread

Is there a delay in select() of JTextComponent? Jan Burse <janburse@fastmail.fm> - 2012-12-02 18:29 +0100
  Re: Is there a delay in select() of JTextComponent? Jan Burse <janburse@fastmail.fm> - 2012-12-02 18:52 +0100
  Re: Is there a delay in select() of JTextComponent? Jan Burse <janburse@fastmail.fm> - 2012-12-02 19:09 +0100

csiph-web