Closed gasparschott closed 1 year ago
I don't know when I might get to this, but if KM can parse JSON, you can look in .obsidian/workspace.json
for the following:
"ophidian:layout-settings": {
"pane-relief:focus-lock": true
},
That will tell you if focus lock was engaged as of the last save of the workspace. As long as you're not switching it on and off every few seconds that should probably give you what you need.
Excellent suggestion! Thanks. That worked.
On Aug 19, 2023, at 10:01 PM, PJ Eby @.***> wrote:
I don't know when I might get to this, but if KM can parse JSON, you can look in .obsidian/workspace.json for the following:
"ophidian:layout-settings"
: {
"pane-relief:focus-lock"
:
true
},
That will tell you if focus lock was engaged as of the last save of the workspace. As long as you're not switching it on and off every few seconds that should probably give you what you need.
— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>
I'm trying to set up a couple of Keyboard Maestro macros (1) to navigate from tab to tab, turning off sidebar focusing if necessary, and (2) to navigate to the sidebar, turning on focusing if necessary.
Currently, the only way I can see to accomplish is to have KM look for the lock or unlocked icon in the status bar, and click it if needed, but the difference between the two icons is evidently too slight for KM to be able to tell the difference. The result is that KM toggles the focus each time I invoke the macros, so that half the time the focusing is not what I want.
If there were separate hotkeys to enable and disable sidebar focusing, I could use each only where needed in the macros.
Thanks.