camickr wrote:Thanks for the post. What I understand is here below..
A peer component is the OS specific equivalent component. AWT just exposes an API that allows you to set properties of that component. So when you create an AWT Button, you ultimately create a "button object" on the OS that you are using. The OS is responsible for painting the button and responding to events.
It seems you are trying to say default button color changes in mac , windows and linux because OS is responsible for painting the button.Yes.
what is the OS specific equivalent component here in this button example ? Does it have a name ? what it is called ?I don't know or care. I don't work at a low level so I don't know what the OS calls each object. That is why we use higher level programming languages so we don't have to worry about the details of how the OS works. Java especially works this way since its goal is to "write once run everywhere".