(2) The term also refers to the program that is written in order to make the graphic widget in the GUI look and perform in a specified way, depending on what action the user takes while interfacing with the GUI.
The term widget is used to refer to either the graphic component or its controlling program or to refer to the combination of both.