如何在PHPExcel中获得excel表的样式

Good evening, i am reading excel file with PHPExcel, it works fine but i dont know how to get styling from excel table.

I read that there is some getStyle() method in PHPExcel, but i am not sure where to use it, so far my tests have failed.

Here's what i got so far:

$allDataInSheet = $objPHPExcel->getActiveSheet()->toArray(null,true,true,true);
$arrayCount = count($allDataInSheet);
for($i=2;$i<=$arrayCount;$i++){
    $data1 = trim($allDataInSheet[$i]["A"]);
    $data2 = trim($allDataInSheet[$i]["O"]);
    echo $data1.$data2."<br>";
}

Can anyone advise how should i get styling (font color, underline etc.) also ?

Using the getStyle() method:

$objPHPExcel->getActiveSheet()->getStyle('A10');

This will return a PHPExcel_Style object, detailing all the style elements set for cell A10