are you using graphics class for drawing the rectangular boundary for the buttons ?