Not true. Do your homework.
He wrote Two New Sciences while under house arrest after the Inquisition found him a heretic.
http://books.google.com/books?id=ewKMpRsF4Y8C&pg=PA47#v=onepage&q&f=false
http://books.google.com/books?id=KBKSyHOLzZAC&pg=PA96#v=onepage&q&f=false
http://en.wikipedia.org/wiki/Galileo_Galilei