Davis
Date: Thursday, September 19, 2024 at 11:30
To:
Cc: openjfx-dev@openjdk.org
Subject: Re: How navigation currently works in FX, and an enhancement proposal
Focus traversal in JavaFX is one of the two things I miss most about Swing.
With Swing we could access the policy and move to the next
JavaFX doesn’t have many ways of prioritizing key event handling. On Windows
and Mac there are mechanisms in place specifically to ensure ESC gets channeled
to a dialog’s default cancel button. These mechanisms also prioritize menu
accelerators before other uses. In JavaFX key events have to bub
On 20/09/2024 23:31, Thiago Milczarek Sayão wrote:
Hi,
I feel shy to add any thoughts on this. So don't mind if I don't make
sense of it:
I don't think all key bindings qualify as "navigation", but pressing
ESCAPE on a text input control will eat the key even if there's no
edit to cancel.
Cheers,
-andy
From: openjfx-dev on behalf of Thiago Milczarek
Sayão
Date: Friday, September 20, 2024 at 14:31
To: John Hendrikx
Cc: openjfx-dev@openjdk.org
Subject: Re: How navigation currently works in FX, and an enhancement proposal
Hi,
I feel shy to add any thoughts on this. So don't
Hi,
I feel shy to add any thoughts on this. So don't mind if I don't make sense
of it:
I don't think all key bindings qualify as "navigation", but pressing ESCAPE
on a text input control will eat the key even if there's no edit to cancel.
So if you bind ESCAPE on the Scene as a shortcut (for clo
John,
I agree, the ScrollPane should not consume arrow keys when it doesn’t have
focus.
Under what conditions does the ScrollPane see these keys? With a TableView the
focus either lies on the TableView itself or on one of the controls in the
table. In the former case the ScrollPane won’t be in
That is exactly what FX needs per your examples.
On Thu, Sep 19, 2024 at 11:48 AM John Hendrikx
wrote:
> oneOfMyNodes.getScene().focusNext();
>
> or:
>
> oneOfMyNodes.getScene().focus(Direction.NEXT);
>
And why should every developer have to do their own utilities to accomplish
some
This should certainly also become possible at some point. There already
is internal API to find the next/previous or left/right Node, it is more
a question how to expose this as an API at this point.
For this specific case, you'd probably want to change focus in an
ActionEvent, or possibly a
Focus traversal in JavaFX is one of the two things I miss most about
Swing. With Swing we could access the policy and move to the next or
previous object programmatically -- a feature that is sadly lacking in FX.
For those of us old enough to remember the good old days of character
interfaces, hit
I've been looking into how exactly navigation keys are being used in FX,
and who is responsible for handling them:
- Controls can choose to install navigational keys directly in their
input map (using FocusTraversalInputMap::getFocusTraversalMappings)
- Controls can choose to do nothing and lea
10 matches
Mail list logo