This wouldn't be a problem if the underlying operating system APIs wouldn't treat accessibility as an opaque "feature" baked into their UI frameworks.
There should/could be open accessibility APIs in each OS which sit between (e.g.) screenreader software and custom UI frameworks.