Example #1
0
 /**
  * Generate the pdf of one label (can be modified using SetGenerator)
  *
  * @param string $text
  */
 public function generateLabel($text)
 {
     $args = array('w' => $this->width, 'h' => 0, 'txt' => $text, 'border' => 0, 'align' => 'L', 'fill' => 0, 'ln' => 0, 'x' => '', 'y' => '', 'reseth' => TRUE, 'stretch' => 0, 'ishtml' => FALSE, 'autopadding' => FALSE, 'maxh' => $this->height);
     CRM_Utils_Hook::alterMailingLabelParams($args);
     if ($args['ishtml'] == TRUE) {
         $this->writeHTMLCell($args['w'], $args['h'], $args['x'], $args['y'], $args['txt'], $args['border'], $args['ln'], $args['fill'], $args['reseth'], $args['align'], $args['autopadding']);
     } else {
         $this->multiCell($args['w'], $args['h'], $args['txt'], $args['border'], $args['align'], $args['fill'], $args['ln'], $args['x'], $args['y'], $args['reseth'], $args['stretch'], $args['ishtml'], $args['autopadding'], $args['maxh']);
     }
 }