Add option to contextual menu to learn a new word... is it possible? [SOLVED]

UPDATE: see solution at the bottom of the post

As a Portuguese native speaker, but with a computer 100% in English (and I write in English 99.99% of the time), sometimes I find myself adding new Portuguese words to the System Preferences > Keyboard > Text tab so when I write a word such as nao, it automatically converts it to não.

It's a bit "annoying" to always open System Preferences, etc.

Is there a way through BTT to add an a trigger that adds an option to the contextual menu when highlighting a word and right clicking that will open the Text tab automatically inside System Preferences > Keyboard?

Hope it makes sense...

I'm thinking maybe BTT can read a script that opens that tab?
If so, anyone with an idea how that script would look like?

Thank you :slight_smile:


Update
Just found a script and running that script as trigger, did the work.
For anyone interested, here's the script:

tell application "System Preferences"
	activate
	set current pane to pane id "com.apple.preference.keyboard"
	tell application "System Events"
		click radio button "Text" of tab group 1 of window "Keyboard" of application process "System Preferences"
	end tell
end tell
2 Likes