How Do I set the Width of the KM Prompt with List Action?

prompt

#1

Dan's macro is superb, except that there is a severe delay in its operation, and that delay is so long that I don't use his macro. I have a list of thousands of text entries, each of which is a paragraph. I need the list to be full width, but using Dan's macro means I have to wait up to two seconds for the prompt to appear, then it's also slow as I type in the box. I really just want to be able to set the width of KM's built-in Prompt With List (either in pixels or ideally in %). Has anyone come up with a way of doing this? KM's Prompt With List is instantaneous, but it's not wide enough (regardless of the choice of settings in the editor). I need to see long sentences to make my choice from the list.


KM to 'type' in the Prompt With List field
#3

What’s New in 8.1

  • Added configurable width to Prompt With List action. (forum)

Always look for the highlighting in the gear menu that indicates there are additional infrequently used options:

image


#4

Peter, thanks for pointing this out.

I think we'd have this conversation before, but I have to once again point that for at least some of us the light grey/blue fill color on a light grey background is very hard to notice. I would prefer something more obvious, like red:

image


#5

I'm aware of the choices of width, but none of them is sufficiently wide.


#6

Hey @thoffman666

How wide do you want it?

Show an example picture of the inadequate Prompt with List compared with an example image of Dan's Spotlight Prompt that does fit the bill (at least size-wise).

Show a use-case that might convince Peter it's worth the effort to add a feature – perhaps a user-configureable size...

-Chris


#7

I could post images, but it's not hard to imagine. I need it to be 100% of the width of my screen. Even then only parts of the entries will be visible. That's why I was so hopeful about Dan's macro, because HTML is ideal for setting 100% width, but the slowness makes it unusable. I was hoping KM's Automatic Width option would size to as large as possible given the length of entries, but that's not the case. It appears that Automatic Width only makes it smaller than Wide when entries are short, but it never goes wider than Wide (which is not very wide at all).


#8

I'll be very surprised if Peter will entertain that idea, but he'll confirm for himself.

You can make an AppleScript choose from list command very wide, but thousands of entries and type-select but NOT filtering would make that problematic.

Your best bets if you want a solution anytime soon are (IMO):

A) Use a running instance of Safari or Chrome to provide the UI for your script.

B) Ask on the LNS Forum and see if this can be done via AppleScriptObjC. (I think so, but I haven't done it and therefore can't be certain.)

C) Build your own app with something like XOJO.

-Chris


#9

I find that very surprising, and not consistent with my experience. I have used MACRO: Spotlight Search Prompt by @DanThomas for a number of tasks/macros, including one that has about 2,000 lines X 100 characters, and it is very fast, near instantaneous for me.

But, if you are wanting a display that is as wide as your monitor, I guess it could be a problem if you also want to have many thousands of lines. Perhaps you could provide the specifics of your data (#lines, avg chars per line) that we could test.

However, I have to say that your requirement is not well suited for displaying a very large list, and then doing an incremental search as you type. I'd suggest that you break it down into at least two steps:

  1. First filter the entire list by one or more keywords, without displaying any data (unless you have a reasonable list of keywords to select from.
  2. Use the selected keywords to build a new list to select from using Dan's tool, provided this new list is of reasonable size.

It also occurs to me that trying to directly select a line from thousands of lines that are hundreds of characters wide doesn't make a lot of sense to me. Do you mind sharing the real-world use case that requires this? If we better understand your requirements we can offer better solutions.


#10

Thanks to both of you. I use it to choose responses to questions about a huge variety of topics. A typical entry in the list is 500-600 characters, and the list is ever-growing. Dan's macro was taking multiple seconds to pop up, then a second or so after each keystroke to search the list. I came up with a dirty workaround using a custom HTML prompt, and it works well as far as instantaneously searching and full width are concerned, but it involves a mouse click to choose the response. That's because I can't figure out how to implement arrow key navigation through the list items that are displayed below the search text input. If anyone has a generic example of how to do that, it would be neato.


#11

But there's no obligation to pick the full, literal response from the list. Apart from the issues you've already stumbled into, it isn't very efficient reading choices across the width of the screen.

You might instead use a short description of the problem or solution each text item is intended for in your pick list then use a switch statement to evaluate what was chosen and paste in the appropriate boilerplate.