I submitted a patch for another module, composite (on the composite_cck file). But this patch uses a notion which could be used for a more generic purpose.
I invite you to read the issue here.
Here is the explanation :
It could be great to specify a formatter for a field which check some conditions, such as :
- I want to apply this formatter on an imagefield, but only jpeg extension.
- I want to format a referenced node with only title and two more custom fields, so only apply on my custom content type...
I'm confident we could find a lot more use cases, and it does not need a lot of code to add this functionnality, juste declare what is called a "suitability callback" on your formatter (see the referenced issue).
Maybe we can share this issue with all projects dealin with field formatters...
Best regards,
Raphael

Comments

sdelbosc’s picture

I gave my opinion there: http://drupal.org/node/773318#comment-2875370
Is there anybody sharing the same?