Uploaded image for project: 'Apache Flex'
  1. Apache Flex
  2. FLEX-34724

DateTimeAxis formats dates strangely when labelUnits is milliseconds

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • Apache Flex 4.13.0
    • None
    • Charts
    • None

    Description

      When labelUnits on a DateTimeAxis is set to "milliseconds" then the axis labels are formatted like: "14:02:230123" The milliseconds are attached on to the end of the minutes, separated with a "0". This seems bizarre to me and I would be surprised if this is the intended behavior.

      The expected behavior, for me, is for the labels to be formatted like "14:02:23.123" - i.e. with a "." separating the seconds and the milliseconds.

      See the attached screenshot for an example of the weird behavior.

      If someone from the Flex team can confirm this is something that should be changed, I can try and submit a patch. The pertaining code is in DateTimeAxis.formatMilliseconds(...) - it looks pretty weird to me anyway: it contains an if-branch that will always be taken, and some unnecessary string allocation.

      Attachments

        1. weird-graph-label.png
          14 kB
          Gareth Daniel Smith

        Activity

          People

            Unassigned Unassigned
            garethdanielsmith Gareth Daniel Smith
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: