Quickly Select Up to a Given Character (Repeatable)

Many years ago I used a feature in an editor that allowed me to quickly expand a selection from the beginning of a paragraph to a given character. I can't remember whether it was MS Word for DOS or another retro editor or word processor :). (If I remember correctly, the feature was triggered by the forward slash.)

Since CafeTran Espresso doesn't offer a quick selection feature (yet), I decided to create a macro that allows me to quickly select the beginning of a target segment up to a given character. Once the selection exists, I can make all kinds of modifications (deletion, change to lowercase, cut etc.).

2gif
Expand selection to user-defined character (repeatable).kmmacros (18.0 KB)

1 Like

That's quite an accomplishment you've made here. I'm glad you've succeeded with a tricky macro to solve a tricky problem.

I've created a new version, bypassing the Prompt:

The Main macro:

Main can call two macros, depending on the existence of a selection (or not):

No selection exists:

A selection does exist:

The macros:
Quickly Expand Selection Macros.kmmacros (33.9 KB)

Demo:

2gif

1 Like

Another new version: tag handling for CafeTran Espresso has been implemented now (only native tags, for the time being):

1
Quickly Expand Selection with Tag Handling Macros.kmmacros (37.6 KB)

1 Like