You are here

function signaturefield_field_formatter_info in SignatureField 7

Same name and namespace in other branches
  1. 6 modules/content.inc \signaturefield_field_formatter_info()
  2. 7.2 includes/field.inc \signaturefield_field_formatter_info()

Implements hook_field_formatter_info().

We need to tell Drupal that we have two different types of formatters for this field. One will change the text color, and the other will change the background color.

See also

signaturefield_field_formatter_view()

File

includes/field.inc, line 70
Content module integration.

Code

function signaturefield_field_formatter_info() {
  return array(
    // The machine name of the formatter.
    'signaturefield_formatter' => array(
      // The human-readable label shown on the Display
      // fields screen.
      'label' => t('Signature image'),
      // An array of the field types this formatter
      // can be used on.
      'field types' => array(
        'signaturefield',
      ),
    ),
  );
}