KoolReport's Forum

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

Legend items for charts #50

Open zenon opened this topic on on Aug 2, 2017 - 4 comments

zenon commented on Aug 2, 2017

Hi,

Can the legend items include the values in the, let's say, pie chart? Eg: How could the legend items be changed from Category A to Category A(15%)? The purpose of this is because some values does not appear on the pie chart, especially for small pies when printing, although we can see the values when the mouse is hovered.

Appreciate your help. Thanks.

KoolReport commented on Aug 2, 2017

Hi, you do this:

<?php
PieChart::create(array(
    ...
    "options"=>array(
            ...
            "legend"=>array(
                  "position"=> 'labeled',
                  "labeledValueText"=> 'both',              
            )
    )
));
?>
sneha narnaware commented on Aug 2, 2018

how to show cursor:pointer on legends in line charts

KoolReport commented on Aug 3, 2018

You may do:

LineChart::create(array(
    ...
    "clientEvents"=>array(
        "itemSelect"=>"function(){}"
    )
))

By default, Google Chart does not have pointer on item select but we do add it when "itemSelect" event is set.

sneha narnaware commented on Aug 3, 2018

Thank you so much its working as I expected ....

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
None yet

None