So I first bought a new Cooler Master keyboard. It does not work with a KVM switch, as I discovered when it arrived. So it went back.
Then I bought a Taiwanese keyboard. It also does not work with a KVM switch, so it is also going back.
Now, I have ordered a DAS keyboard. It claims to work with a KVM switch. I hope that this is accurate...