Skip to content

Commit

Permalink
close #1967
Browse files Browse the repository at this point in the history
  • Loading branch information
kif committed Oct 5, 2023
1 parent d67df16 commit 291300e
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions pyFAI/gui/tasks/IntegrationTask.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

__authors__ = ["V. Valls", "J. Kieffer"]
__license__ = "MIT"
__date__ = "05/09/2023"
__date__ = "05/10/2023"

import logging
import numpy
Expand Down Expand Up @@ -839,7 +839,12 @@ def compute_location(result):
scale=(scaleX, scaleY),
colormap=colormap,
resetzoom=False)
self.__plot2d.setGraphXLabel(result2d.unit.label)
unit = result2d.unit
if isinstance(unit, (tuple, list)) and len(unit) == 2:
self.__plot2d.setGraphXLabel(unit[0].label)
self.__plot2d.setGraphYLabel(unit[1].label)
else:
self.__plot2d.setGraphXLabel(unit.label)

self.__radialUnit = integrationProcess.radialUnit()
self.__wavelength = integrationProcess.wavelength()
Expand Down

0 comments on commit 291300e

Please sign in to comment.