I do not know why this happens.
The keyboard backlight appears to behave incorrectly (on Mac computers that have this feature).
Reset SMC. http://support.apple.com/kb/HT3964
Choose the method for:
"Resetting SMC on portables with a battery you should not remove on your own".
Thanks for your suggestion dominic23. I think my system might have been working correctly all along. After a bit of experimentation with the backlight settings I have found the following:
- The tick box in the keyboard preferences is labelled "Automatically illuminate keyboard in low light".
- If the tick box is unchecked the keyboard illuminates at all times, no matter how bright the ambient light is.
- You can dim the keyboard or make it brighter with the F5 and F6 keys respectively. Setting the level to zero effectively turns it off.
- If the tick box is checked then when you shine a bright light at the sensor (which is near the camera) the keyboard illumination automatically shuts off whilst the light is present.
So things seem to be working OK, if somewhat counter-intuitively.
It might be just me but I think it would have made more sense if Apple had labelled the tick box "Automatically turn off keyboard illumination in bright light".