Prompt for User Input Action (v10.0.2)

The action, below, is one we've used for a couple years. In previous versions of KM it could be set by simply typing the first characters of a given line (without even clicking the pulldown menu). Since updating to KM 10 that no longer works. I also notice we can no longer type "Space Bar" to trigger the "Cancel" button in KM Prompts. I assume this is related. Is this a known issue?

Prompt for User Input.kmactions (1.1 KB)

I can't speak with any authority as to your first issue, but for the space bar issue you can append your Cancel text as show in the example below (you don't actually need the (SPC) but, I just always put that in as a visual cue to what the keyboard shortcut is for each button).

Note that there is an actual space in front of the forward slash for the cancel option.

Prompt for User Input.kmmacros (2.5 KB)

Macro screenshot (click to expand/collapse)

1 Like

My experience is that the default button is ALWAYS triggers by "Enter" or "Return". And, until KM 10 Space Bar ALWAYS triggered Cancel.

Your example does not work for me. I typically add a shortcut to a specific button with
Button/b.

Editing the Cancel button to read "Cancel/c" does allow it to cancel with "c" keyboard character. But I really liked the default "SpaceBar" functionality.

The problem with adding a "/" after "Cancel" is that it loses the default status of the other button.

Hmmm.... that's odd BUT I have been using custom appended buttons for so long I don't really know much about the default behavior. Looks like @Zabobon is replying though, so he'll likely know more (seems like he and I are always replying at the same time :laughing:).

Hi @rcraighead I think the reason the example you posted doesn't cancel when the spacebar is tapped is the it is waiting for input for the Variable "Digit". Any key you type will only highlight that field.

I can confirm that "Return" still works for OK and "Spacebar" still works for Cancel in KM 10.0.2

@cdthomer, can you confirm that the pulldown menu is NOT triggered by typing the first characters of a line item? This was standard in KM 9.

Thanks, @Zabobon. Can you confirm that typing the first characters of one of the pulldown menu line items does "NOT" open and select the line? This no longer works for me in KM 10. It was a nice feature of earlier versions.

"SpaceBar" no longer works on ANY KM 10 Prompts. It was standard using the same macros in KM 9.

Yes, the default (blue) button still triggers with "Enter" or "Return". That has not changed.

@Zabobon, this is not how the same action worked in KM 9. Before KM 10 I could start typing and the line item would be selected, then typing "Return" or "Enter" would close the Prompt. It was a beautiful thing. :slight_smile:

Actually the space bar does not work for me to cancel... also on KM 10.0.2

1 Like

Can confirm, typing does nothing for me.

1 Like

"esc" key will still cancel a KM 10 prompt even though space bar no longer works for me.

Same here. But I imagine this is by design since space bar in other apps could mean continue/proceed and not cancel.

Could be. I'm more interested in regaining the ability to access the pulldown menu just by typing than about the change in "Cancel".

If I remember right, in KM 9 I could also open the prompt pulldown menu by typing the "down" arrow key.

1 Like

That still works for me.
macOS Monterey 12.1 KM 10.0.2

1) Prompt with no dropdown or highlighted field (in effect it is the Cancel button that has the blue highlight around it)
Return key, for OK
Spacebar, for Cancel (if that is the button with the blue highlight around it).
Esc, for Cancel - if you name the button Cancel/.

2) Prompt with dropdown
EDIT: Type first letter selects item in dropdown list (after a slight pause as @drdrang noted in the following post)
Arrow key down, to select list and then you can type first letter to select
Spacebar, to select list (as that is the item with the blue highlight around it) and then you can type first letter to select
Return to accept the choice
Return key, for OK
Esc, for Cancel - if you name the button Cancel/.

I'm using KM 10.0.2 and typing characters after the window appears does select a menu item, but there is a pause before that happens. Also, typing the down arrow key cause the menu to open up.

I am still running Big Sur, so that may be the reason it works for me.

Also, I believe spacebar is like tapping whatever item is currently selected (has a ring around it), which is not necessarily the Cancel button. Escape and Command-Period are synonyms for Cancel.

2 Likes

Ah, that's interesting. So, the reason Spacebar works to cancel in my test is that the Cancel button had the blue highlight around it. In the second one with the dropdown Spacebar selects the dropdown because that is the item with the blue highlight around it. I suspect this is standard Mac OS behaviour and not particular to Keyboard Maestro?

And also interesting that just typing the first letter does select the item (after the slight pause). In trying to answer this I've learnt new things too!

I'll edit my post above to avoid confusion.

1 Like

Well, that's hopeful. In my experience, the "Default" button (blue button) is the top button defined in the prompt action unless it is assigned a shortcut.

image

image

Yes, when it was working, there WAS a short pause after typing before the menu item was selected.

SpaceBar used to "Cancel" by default.

Yes, if I manually open the dropdown, then I can type to select a line, but this was not necessary in KM 9. Just typing the 2-character prefix selected the correct line without opening the dropdown.

This no longer works on High Sierra for my work associates.

Hi @rcraighead I think you are going to be very happy because the answer to why this is not working is in Mac System Preferences:

With option unchecked gives this:

image

With option checked gives this:

image

Without the blue highlight around things you can't use Keys to navigate dialog boxes and it is off by default.

I think because we all tend to set this option to on we all forgot about that.

3 Likes