Skip to content

missing data gap clipping should honour line width #1109

@michi42

Description

@michi42

Currently the gap clipping for missing data does not take into account the fact that a line width > 1 can lead to pixels being painted outside of the strict boundaries of a gap. This is particularly true if the data is significantly different between the start and end points of the gap.

For instance if on https://leeoniya.github.io/uPlot/demos/missing-data.html you modify

data[2][92] = 0.1
data[2][93] = 0.1
u.series[2].width=3
u.setData(data)

you get a part of the line connecting the gap, which should have been clipped away, visible:
Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions