mslonik / Hotstrings

AutoHotkey oriented GUI to Hotstrings

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

FR/Help wanted: Exclude programs from executing specific/all libraries

Gewerd-Strauss opened this issue · comments

Hello mslonik,

I am aware that this is a super niche request, thus I'm not expecting you to pick this up yourself. But I'd appreciate a bit of help trying to get this hacked together on my end.
All in all, I'd like to be able to exclude certain windows from executing specific libraries alltogether. As an example, I require both latex and unicode math symbols extremely frequently (as in, within a couple seconds of each other) - and for those cases, having both active/the wrong one active is a huge pain. Currently, I have to manually toggle which libraries are active, which obviously gets really annoying if you have to switch them very frequently.

Thus, I'd like to be able to ban specific (or, in the worst case all) libraries from executing in specific programs, or just the program altogether. I'd appreciate if you could point out if/where one would make the corresponding edits.

Thank you.
Sincerely,
~Gw

Hello Gewerd-Strauss,

This is easier to do than you expect. Below you'll find a sketch, you to accomplish it.

All you need is to run more than one instance of Hotstrings application. Just download the freshest release. Name one script as e.g. Hotstrings1.ahk, the second as Hotstrings2.ahk. Create separate Libraries subfolders. In each subfolder place Before running both instances prepare separate AutoHotkey script which will define context for both instances according to your liking.

For your information, I run two instances of Hotstrings as some libraries overlap if run from just single instance. Thanks to that I can for example automatize capitalization of letters when new sentence is started.

I hope it will help you resolve your issue.

By the way I didn't notice any upload of your libraries to free libraries repository ever (https://github.com/mslonik/Hotstrings-Libraries). I'd appreciate to spread the word about this application too.

Kind regards, mslonik (🐘)

Hello mslonik,

First of, thank you for your reply. I'll try and take a closer look at this in about two weeks, currently I am bogged down with university hell week coming up and my rent contract ending at the same time, so I unfortunately have absolutely zero time to start on this right now.

Sincerely,
~Gw

@AstudilloMarillo you can suspend the application from the tray-menu. This will disable all hotstring triggers, however the tooltip will still show up as you go. That might solve your issue.

If this does not fulfill your needs, I believe the simplest alternative is to kill the script during game-sessions.
In principal, you could even write a simple script that waits in the background until <a game> was launched, and then kills the script for you. Similarly, it could restart the script once no game is running anymore (or even when tabbing out, but I think that might be excessive).