Page 1 of 1

Space/Separation between bars with TeeChart for .Net

Posted: Thu Jun 22, 2023 8:46 am
by 15695876
Hello,

When i plot two bars the separation between them is a bit too much, what could i do to shorten this distance?
Image

How could o control the space between bars independently of how many there are?

Thank you.

Re: Space/Separation between bars with TeeChart for .Net

Posted: Thu Jun 22, 2023 4:21 pm
by Christopher
Hello,
David N. wrote:
Thu Jun 22, 2023 8:46 am
When i plot two bars the separation between them is a bit too much, what could i do to shorten this distance?
This can be achieved by compressing the bottom axis with offset pixels, e.g.

Code: Select all

       public Form1()
        {
            InitializeComponent();

            var bar = new Bar(tChart1.Chart);

            bar.Add(1);
            bar.Add(10);

            tChart1.Axes.Bottom.MinimumOffset = 170;
            tChart1.Axes.Bottom.MaximumOffset = 170;
        }