Ignore:
Timestamp:
Nov 9, 2017 8:43:55 AM (6 years ago)
Author:
Piotr Rozyczko <rozyczko@…>
Branches:
ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc
Children:
d6b8a1d
Parents:
7969b9c
git-author:
Piotr Rozyczko <rozyczko@…> (11/03/17 10:58:39)
git-committer:
Piotr Rozyczko <rozyczko@…> (11/09/17 08:43:55)
Message:

More Qt5 related fixes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/sas/qtgui/Calculators/KiessigPanel.py

    r4992ff2 rfbfc488  
    5555            self.thickness.set_deltaq(dq=float(self.deltaq_in.text())) 
    5656            kiessing_result = self.thickness.compute_thickness() 
    57             float_as_str = "{:.3f}".format(kiessing_result) 
    58             self.lengthscale_out.setText(float_as_str) 
     57            if kiessing_result: 
     58                float_as_str = "{:.3f}".format(kiessing_result) 
     59                self.lengthscale_out.setText(float_as_str) 
     60            else: 
     61                # error or division by zero 
     62                self.lengthscale_out.setText("") 
     63 
    5964        except (ArithmeticError, ValueError): 
    6065            self.lengthscale_out.setText("") 
Note: See TracChangeset for help on using the changeset viewer.