Prompt List as Context Menu [Macro:KM10]

Purpose: Using Prompt List as context menu

*This only work for KM10 because it uses the new token PromptWithListText [token:PromptWithListText [Keyboard Maestro Wiki]]

This is one of the few design patterns I used to build sophisticated macros. Design patterns are common patterns use in software development to reuse common 'proven' ways to build software [Software design pattern - Wikipedia]. It is useful to define design patterns for KM since it will help expedite macro development especially KM provide numerous ways of doing things.

Prompt With List is one of the most interesting and useful actions that I use frequently since it can perform real-time search. I use to it for example, to store the whole KM macro names, whole KM Variables, web links, commonly accessed files and directories. It can support more than !0,000 items without sweat.

This demo shows

  • How [Prompt with List] Action can be used to show list of items (eg products) and leverage its real-time search facility
  • Prompt List as 'operation' context menu
  • Leverage on new KM token PromptWithListText to show recent filter (so one does not need to re-enter the recent filter again)

Use-case:
The user activates the item prompt List and enters 'commercial' to filter list of item. He selects an item and Ctrl+DoubleClick (context menu) on the item to perform Edit. (Ctrl is used because Mac use it to show context menu eg Ctrl+Click)

User want to reuse the last filter 'commerical' to display the prompt list again. He long-press CMD key to show those filtered list again, otherwise normal press will show ALL items.


[EKM] Prompt List as Context Menu Demo.kmmacros (8.2 KB)

2 Likes