I've found a couple of examples of creating a content type using visual studio.
http://stevemannspath.blogspot.com/2010/11/sharepoint-2010-leveraging-visual.html
http://msdn.microsoft.com/en-us/library/ff630942.aspx
They both say "Deploy as Farm Solution".
Why cant they be sand box solution?