Pre loader

FastColumnRenderableSeries - how to get a width for Column from code

Welcome to the SciChart Forums!

  • Please read our Question Asking Guidelines for how to format a good question
  • Some reputation is required to post answers. Get up-voted to avoid the spam filter!
  • We welcome community answers and upvotes. Every Q&A improves SciChart for everyone

WPF Forums | JavaScript Forums | Android Forums | iOS Forums

0
0

Hello,

question about FastColumnRenderableSeries:
assuming the UseUniformWidth is set to True (all columns are same width) and Series already displayed: how I could get the actual width for one (any) column from code?

I.e. I do not want to use GetColumnWidth(IPointSeries points, IRenderPassData renderPassData) to computes the width of the columns to be drawn.

Just need to get the actual width for column already drawn.
From code.

Thanks!

-Egor

Version
4.2.5
  • You must to post comments
0
0

Hi Egor

There is no way to get the width of a column drawn, other than to hook into the code in FastColumnRenderableSeries and output an event when column is drawn and report the size.

for example:

    public class FastColumnRenderableSeriesEx : FastColumnRenderableSeries
    {
        public Action<double> OnGetColumnWidth { get; set; }

        protected override double GetColumnWidth(IPointSeries points, IRenderPassData renderPassData)
        {
            double width = base.GetColumnWidth(points, renderPassData);
            OnGetColumnWidth?.Invoke(width);
            return width;
        }
    }

this function (GetColumnWidth) is called once when the column series draws.

Does that help?

Best regards,
Andrew

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.

Try SciChart Today

Start a trial and discover why we are the choice
of demanding developers worldwide

Start TrialCase Studies