Skip to content

ColorMap.getByIndex() returns wrong colors #2627

@pijyoi

Description

@pijyoi

Short description

ColorMap.getByIndex() returns wrong colors.

Code to reproduce

In [1]: import pyqtgraph as pg
In [2]: cm = pg.ColorMap([0.0, 1.0], [(0,0,0), (255,0,0)])
In [3]: cm.getByIndex(0)
Out[3]: PySide6.QtGui.QColor.fromRgbF(0.000000, 0.000000, 0.000000, 0.003922)
In [4]: cm.getByIndex(1)
Out[4]: PySide6.QtGui.QColor.fromRgbF(0.003922, 0.000000, 0.000000, 0.003922)

Tested environment(s)

  • PyQtGraph version: 0.13.2.dev0

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions