at least for windows you can change the keyboard layout to directly output the deadkeys, example for german: https://github.com/RAnders00/Deutsch-ohne-Tottasten
if none is available for your language you can build it yourself: https://zauner.nllk.net/post/0014-windows-no-dead-keys/