Detecting input field background color

Various functions can set my input fields to one of 4 background colors using the form <inputfield>.setStyle(“backgroundColor”, <color>). How can I find out whether my input field has been colored and, if so, to which color?