Select String as a Word in Pages

OK, @ccstone's use of the Find Pasteboard inspired me to give this one last try:

Get Chord.kmmacros (7.5 KB)

This macro will select the whitespace-delimited string that the cursor is in or adjacent to. It does not put that string on the clipboard, although that could be done by adding a Copy command to the end. It's very fast on my M1 MacBook Air, although there is a bit of visual noise as it selects pieces of the current line to set up the search string.

It works if a portion of the whitespace-delimited string is selected, like if you double-clicked on a chord name and got just part of it. It does not work if the cursor is at the beginning or end of a line, although I suspect a little bit of defensive coding could fix that.

It works! Pretty cool, thanks