Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

horizontal legend at the bottom of graph in jqplot

Tags:

legend

jqplot

I m able to get horizontal legend of jqplot graph using EnhancedLegendRenderer plugin.But i need horizontal legend at the bottom of the graph .Any suggestion?

like image 756
Code4Fun Avatar asked Apr 05 '13 06:04

Code4Fun


1 Answers

You should always show some work when posting to stack overflow. It helps us understand your problem.

I think you are having a problem with EnhancedLedgendRenderer based on your description.

This is what my code looks like to achieve a 1 row, 3 column legend.

          legend: {
        // This renderer is needed for advance legends.
        renderer: jQuery.jqplot.EnhancedLegendRenderer,
        show: true, 
        location: 's', 
        placement: 'outside',
        // Breaks the ledgend into horizontal.
        rendererOptions: {
          numberRows: '1',
          numberColumns: '3'
        },
        seriesToggle: true
      },

Also, you are probably getting down voted because of punctuation and lack of capitalization.

like image 186
pizoelectric Avatar answered Sep 23 '22 16:09

pizoelectric