#1109·uPlot

missing data gap clipping should honour line width

Author: michi42Created Nov 12, 2025Updated Nov 17, 2025

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