You are here

private function PHPExcel_Writer_Excel2007_Chart::_writeLegend in Loft Data Grids 6.2

Same name and namespace in other branches
  1. 7.2 vendor/phpoffice/phpexcel/Classes/PHPExcel/Writer/Excel2007/Chart.php \PHPExcel_Writer_Excel2007_Chart::_writeLegend()

Write Chart Legend

Parameters

PHPExcel_Chart_Legend $legend:

PHPExcel_Shared_XMLWriter $objWriter XML Writer:

Throws

PHPExcel_Writer_Exception

1 call to PHPExcel_Writer_Excel2007_Chart::_writeLegend()
PHPExcel_Writer_Excel2007_Chart::writeChart in vendor/phpoffice/phpexcel/Classes/PHPExcel/Writer/Excel2007/Chart.php
Write charts to XML format

File

vendor/phpoffice/phpexcel/Classes/PHPExcel/Writer/Excel2007/Chart.php, line 180

Class

PHPExcel_Writer_Excel2007_Chart
PHPExcel_Writer_Excel2007_Chart

Code

private function _writeLegend(PHPExcel_Chart_Legend $legend = NULL, $objWriter) {
  if (is_null($legend)) {
    return;
  }
  $objWriter
    ->startElement('c:legend');
  $objWriter
    ->startElement('c:legendPos');
  $objWriter
    ->writeAttribute('val', $legend
    ->getPosition());
  $objWriter
    ->endElement();
  $layout = $legend
    ->getLayout();
  $this
    ->_writeLayout($layout, $objWriter);
  $objWriter
    ->startElement('c:overlay');
  $objWriter
    ->writeAttribute('val', $legend
    ->getOverlay() ? '1' : '0');
  $objWriter
    ->endElement();
  $objWriter
    ->startElement('c:txPr');
  $objWriter
    ->startElement('a:bodyPr');
  $objWriter
    ->endElement();
  $objWriter
    ->startElement('a:lstStyle');
  $objWriter
    ->endElement();
  $objWriter
    ->startElement('a:p');
  $objWriter
    ->startElement('a:pPr');
  $objWriter
    ->writeAttribute('rtl', 0);
  $objWriter
    ->startElement('a:defRPr');
  $objWriter
    ->endElement();
  $objWriter
    ->endElement();
  $objWriter
    ->startElement('a:endParaRPr');
  $objWriter
    ->writeAttribute('lang', "en-US");
  $objWriter
    ->endElement();
  $objWriter
    ->endElement();
  $objWriter
    ->endElement();
  $objWriter
    ->endElement();
}