added a Figure class