KoolReport's Forum

Official Support Area, Q&As, Discussions, Suggestions and Bug reports.
Forum's Guidelines

How do you Expand the Chart Legends? #32

Closed Hallie Gromek opened this topic on on Jul 19, 2017 - 2 comments

Hallie Gromek commented on Jul 19, 2017

for Google Charts, how do you set the legend to a bigger width or height? Width and Height applies to the chart area.

Thanks

KoolReport commented on Jul 20, 2017

Hi Hallie,

You can change the chartArea width to be smaller so that the legend has more space:

<?php
ColumnChart::create(array(
    ...
    "options"=>array(
        "chartArea"=>array(
            "width"=>"60%",
        )
    )
));
?>

Or you can move the legend to another position "bottom" or "top", there is more space there.

<?php
ColumnChart::create(array(
    ...
    "options"=>array(
        "legend"=>array(
            "position"=>"bottom",
        )
    )
));
?>

Let us know if you need further assistance.

Regards,

KoolPHP Inc

Hallie Gromek commented on Jul 20, 2017

Worked! Thank you!

Build Your Excellent Data Report

Let KoolReport help you to make great reports. It's free & open-source released under MIT license.

Download KoolReport View demo
help needed

None