Pre loader

Tag: updateTicks

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 votes
3k views

Hello,

I am having some difficulties using a custom DateTickProvider.

I am trying to offset the values to “anchor” the chart to specific local time (see original question at “https://www.scichart.com/questions/android/axis-value-anchor” for details)

class CustomDateTickProvider() : DateTickProvider() {
    override fun updateTicks(minorTicks: DoubleValues, majorTicks: DoubleValues) {
        // super appears to sometimes recalc based on GMT, and sometimes provide offsets from my previous offsets.
        super.updateTicks(minorTicks, majorTicks) 

       // My offset code here, assumes tick values are GMT based...
    }
}

My code usually works, but sometimes it doesn’t. It appears that when I call super.UpdateTicks(..), it usually generates new ticks based on GMT, but sometimes it simply provides a small offset (like when I pan) based on existing tick values. Is that correct?

Is there a way for me to Force updateTicks to always recalculate based on GMT, or a way for me to tell if updateTicks is recalculating based off GMT or just doing offsets on the existing tick marks?

Or should I be going at this in a different direction?

Thank you.

  • C Bolton asked 3 years ago
  • last active 3 years ago
Showing 1 result

Try SciChart Today

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

Start TrialCase Studies