Keyboard Viewer showing wrong layout after temporary change of keyboard
I am running MacOS Big Sur (11.6.3) on a 4GHz i7 late 2014 27" iMac. The keyboard is an Apple extended keyboard, model A1243, EMC 2171 - the wired version. Today I temporarily connected a non-extended wired Apple keyboard - model A1242, EMC 2159. After going back to the extended keyboard, the keyboard viewer will now show only the physical key layout for the non-extended keyboard, even though it is not connected anymore and the extended one is the only keyboard connected. After trying all related options I could find in System Preferences, I did the usual "fixes" - I reset the SMC and PRAM, started up in Safe Boot Mode, even deleted a few keyboard settings files in the main Library folder (after doing some internet searching as to which ones might be causing this unwanted behaviour), connected a different keyboard (model A1048, EMC 2159). None of those actions made any difference. The other user account on the iMac also displayed the same symptoms, so it appeared that it was not related to the account I normally use. Partly as a measure of desperation but also out of concern that I might have deleted files which are not automatically re-created by the System if found to be missing, I re-installed Big Sur after starting up with Command-R. Even that did not fix the issue! If anyone has any insight as to the cause of this problem and a way to fix it, I would be most grateful to hear from you. It is not a matter of life and death, but it certainly irritates me.
iMac Line (2012 and Later)