Page 1 of 1

Set context window for a group of abbreviation strings (text expander)

Posted: Jun 2nd, ’22, 19:04
by phbfast
Hello,

I would like to group a number of abbreviations (I understood the best way is to group them in a Tab of Text Expander) but then make them (all) active only under a certain context (window/app). For example:
1. I set 3 abbreviations - "phb1", "phb2" and "phb3";
2. When I type "phb" the list of 3 options will pop up so that I can choose which.

Now I want this to be activated only when I'm on a certain app/window. E.g.: Slack.

Is there a simple solution for this (considering that there may be n abbreviations)?

Thanks.

Re: Set context window for a group of abbreviation strings (text expander)

Posted: Jun 2nd, ’22, 22:04
by Marko
Try multiple substitutes.

Abbreviation: phb

Substitute:
First
/Second
/Third

Window: Slack

https://fastkeysautomation.com/documentation5/Send.html

Re: Set context window for a group of abbreviation strings (text expander)

Posted: Jun 3rd, ’22, 19:53
by phbfast
Hi Marko, thanks for your reply.

I had seen the "multiple substitutes" but that did not seem to address what I was looking for.
Apparenty I failed to explain (or biased you) in my previous description by restricting to the same (prefix) abbreviation. What I basically meant was, to see if I could define a number of (different - not same prefix) abbreviations and group/categorize them for different contexts (window/app). I.e., if I place an abbreviation in a "group" it means it belongs to that context(s). Instead of setting the context for each one.

Does that make any sense?

Re: Set context window for a group of abbreviation strings (text expander)

Posted: Jun 4th, ’22, 09:59
by Tom
This is currently not possible, you would need to set the context window for each item.
Alternatively you could group the items into the Phrase file and then set the restriction once.

Re: Set context window for a group of abbreviation strings (text expander)

Posted: Jun 4th, ’22, 18:06
by phbfast
I had a look at the Phrase file option but it appears to be quite limitative. I tried with a substitution phrase with a few (10+) lines and apparently it messes everything. But then I looked at the documentation and presumably that is "expected" since it is meant for "simple Strings and Substitution phrases".

Thanks anyway Tom.
Cheers.

Re: Set context window for a group of abbreviation strings (text expander)

Posted: Jun 5th, ’22, 07:00
by Tom
The limitation is that some macros are not available. Can you give me the example of the problematic phrase?