modified not to change bgcolor when cui-mode