Perhaps you could use a GradientLegend (http://www.pyqtgraph.org/documentation/_modules/pyqtgraph/graphicsItems/GradientLegend.html#GradientLegend) and set its gradient and labels to those of the HistogramLUTItem. If you're exporting the graph, you may need to do some trickery, like hide/remove the HistogramLUTItem and replace it with the GradientLegend, do the export, then put the HistogramLUTItem back. Or if you don't care about the histogram and editing the gradient, just stick with the GradientLegend.
On Friday, 10 August 2018 19:59:38 UTC+9:30, Luka Drmic wrote: > > So i want to export some graphs as png, but i would like it to have only > the main graph and gradient item of the histogramLUTitem. Pretty much what > matplotlib does. Have my main graph (image) and on the side have my > gradient edit item with values next to it. > > I tried hiding everything except the gradient item but that leaves me with > two lines that ure used to slide along axis of LUT item, and in addition to > that it removes axis values, and i wouold like to keep those. > > [image: hideAll.png] > > > > > > > > > Desired items on the export png: > > [image: Desired.png] > > -- You received this message because you are subscribed to the Google Groups "pyqtgraph" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/pyqtgraph/4031a72c-d7a2-4e7a-8b64-4ccf7435b573%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
