Checkboxes options with class in form api I need something like a filter on checkboxes #options in my form built via Form API.
Is there a way to group checkboxes or add a class to filter them via js front side?   

In the documentation options are simply 'value' => 'label'. Can I filter or group them?
To modify how drupal outputs checkboxes, override the default theme_checkbox function found in includes/form.inc. This allow to you add classes and all other stuff. I simply copied the function and changed the last 8 lines:

/* Override theme_checkbox to display titles as facebook-style beautytips  */
function MYTHEME_checkbox($variables) {
  $element = $variables['element'];
  $element['#attributes']['type'] = 'checkbox';
  element_set_attributes($element, array('id', 'name', '#return_value' =&gt; 'value'));

  // Unchecked checkbox has #value of integer 0.
  if (!empty($element['#checked'])) {
    $element['#attributes']['checked'] = 'checked';
  }
  _form_set_class($element, array('form-checkbox'));

  if (substr($element['#name'],0, 13) == "field_MYFIELD") :
    $element['#attributes']['class'][] = 'beautytips';
    return 
      '&lt;input title="' . $element['#title'] .'" ' . 
      drupal_attributes($element['#attributes']) . ' /&gt;';
  else: // Return the regular value
    return '&lt;input ' . drupal_attributes($element['#attributes']) . ' /&gt;';
  endif;
}


Thanks @clive for the inspirtation.