- $this->formatHeaderLeft =& $this->add_format();
- $this->formatHeaderLeft->set_italic();
- $this->formatHeaderLeft->set_top(2);
- $this->formatHeaderLeft->set_top_color('gray');
- $this->formatHeaderLeft->set_bottom(2);
- $this->formatHeaderLeft->set_bottom_color('gray');
- $this->formatHeaderLeft->set_align('vcenter');
- $this->formatHeaderLeft->set_align('left');
- $this->formatHeaderRight =& $this->add_format();
- $this->formatHeaderRight->set_italic();
- $this->formatHeaderRight->set_top(2);
- $this->formatHeaderRight->set_top_color('gray');
- $this->formatHeaderRight->set_bottom(2);
- $this->formatHeaderRight->set_bottom_color('gray');
- $this->formatHeaderRight->set_align('vcenter');
- $this->formatHeaderRight->set_align('right');
- $this->formatFooter =& $this->add_format();
- $this->formatFooter->set_top(2);
- $this->formatFooter->set_top_color('gray');
+ $this->formatHeaderLeft =& $this->addFormat();
+ $this->formatHeaderLeft->setItalic();
+ $this->formatHeaderLeft->setTop(2);
+ $this->formatHeaderLeft->setTopColor('gray');
+ $this->formatHeaderLeft->setBottom(2);
+ $this->formatHeaderLeft->setBottomColor('gray');
+ $this->formatHeaderLeft->setAlign('vcenter');
+ $this->formatDate->setAlign($rtl ? 'right' : 'left');
+ $this->formatHeaderRight =& $this->addFormat();
+ $this->formatHeaderRight->setItalic();
+ $this->formatHeaderRight->setTop(2);
+ $this->formatHeaderRight->setTopColor('gray');
+ $this->formatHeaderRight->setBottom(2);
+ $this->formatHeaderRight->setBottomColor('gray');
+ $this->formatHeaderRight->setAlign('vcenter');
+ $this->formatHeaderRight->setAlign('right');
+ $this->formatFooter =& $this->addFormat();
+ $this->formatFooter->setTop(2);
+ $this->formatFooter->setTopColor('gray');