Apologies, if this is very simple, I am new to this sort of software. I want any text I highlight to automatically be sent to my clipboard so I can easily paste it. However, I just can't make this work. I don't want to use a modifier but if I check allowing it to work without a modifier then my mouse doesn't work.
You can use the relatively new "Text Selection Did Change" trigger. As an action you could either just send cmd+c (to copy the selection), but a less intrusive way is to use this little Java Script:
async function addToClipboard() {
// the text selection did change trigger already makes the BTTTextSelection variable available, thus it's best to retrieve the text from that
let BTTTextSelection = await get_string_variable("BTTTextSelection");
await set_clipboard_content({content:BTTTextSelection, format: 'NSPasteboardTypeString'})
return true;
}
Here is a ready to use example:
auto-copy.bttpreset (1.8 KB)
This was working perfectly fine, but since past few days something strange is happening:
1. Even though I have enabled this only for the terminal, when I select text inside the Citrix Workspace app, it types the character "c" and replaces the selected word with "c". Because of this, I have to disable it for now.
2. Even if I only add the trigger "Text Selection Did Change" without any action and only for Terminal, it still affects text selection in the Citrix Workspace app.
I tried uninstalling and reinstalling BTT, but that didn't help either.
I am on latest release version 6.365
thats strange and dont think this script is causing it but one way to check what IS causing it and if it BTT and if is what action, here is the way to find out, super simple.
Next time you are using Citix Workspace App and the the text is subsitited with just a "c" immeditally open up the BetterTouchTools app and click on the Most Recent Actions icon on left side, usually 2nd icon after ALL, if toolbar is just icons and dont know where to go just extend it to the right like would in say the finder sidebar. Click on Recent Actions and it will show you in order what action just ran and you will have found your bug. Then depending on what it is troubleshoot/disable from there.
