Hi Fabian, note that there are two different on-screen keyboards and it’s the Touch Keyboard that pops up any time a text editor gets or loses focus.
- On Screen Keyboard (Windows Settings >> Ease of Access >> Keyboard)
- Touch Keyboard (Windows Settings >> Devices >> Typing >> Touch Keyboard >> Show the touch keyboard when not in tablet mode and there’s no keyboard attached)
I haven’t looked into programattically querying these.