function GetWidth($aImg)
 {
     $txt = new TextProperty();
     $txt->SetFont($this->iFFamily, $this->iFStyle, $this->iFSize);
     $n = count($this->iTitles);
     $rm = $this->iRightColMargin;
     $w = 0;
     for ($h = 0, $i = 0; $i < $n; ++$i) {
         $w += $this->iLeftColMargin;
         $txt->Set($this->iTitles[$i]);
         if (!empty($this->iWidth[$i])) {
             $w1 = max($txt->GetWidth($aImg) + $rm, $this->iWidth[$i]);
         } else {
             $w1 = $txt->GetWidth($aImg) + $rm;
         }
         $this->iWidth[$i] = $w1;
         $w += $w1;
         $h = max($h, $txt->GetHeight($aImg));
     }
     $this->iHeight = $h + $this->iTopHeaderMargin;
     $txt = '';
     return $w;
 }