Page 1 of 1

Chart boundaries in canvas

Posted: Fri Jan 19, 2018 8:37 pm
by 17782804
I'm trying to have the content of the chart or chart area fill the panel.
I have attached an image and code to in this topic.

Code: Select all

function drawDailyPanel(canvas) {
            var chart;
            chart = new Tee.Chart(canvas);


            chart.addSeries(new Tee.Line()).addRandom(10);

            chart.series.items[0].smooth = 1 / 2;

            chart.title.visible = false;
            chart.title.text = "Smooth Line";


            chart.legend.transparent = false;
            chart.legend.visible = true;

            chart.legend.visible = false;
            chart.axes.visible = false;

            chart.zoom.enabled = false;
            chart.scroll.enabled = false;

           
            //Resize
            resizeDaily(chart);
        }

Thank you,
Ernesto.

Re: Chart boundaries in canvas

Posted: Mon Jan 22, 2018 4:30 pm
by 17782804
I have worked this issue arround by setting axes labels off. (See code from demo)

Code: Select all


...
setLabels(chart, false);

function setLabels(chart, value) {
            chart.axes.left.labels.visible = value;
            chart.axes.top.labels.visible = value;
            chart.axes.right.labels.visible = value;
            chart.axes.bottom.labels.visible = value;
        }