How can I get a list of all available entity view modes? I need to have a list of all available view modes for an entity type so I can use it as the #options in a select field.

Any ideas?
Thanks
I think you are talking about view modes for entities.

$entity_info = entity_get_info('node');
debug(array_keys($entity_info['view modes']));


It would result as

array (
  0 =&gt; 'full',
  1 =&gt; 'teaser',
  2 =&gt; 'rss',
  3 =&gt; 'search_index',
  4 =&gt; 'search_result',
)