Material: comments
This commit is contained in:
@@ -633,6 +633,7 @@ class MaterialsDelegate(QtGui.QStyledItemDelegate):
|
||||
Type = editor.property('Type')
|
||||
model = index.model()
|
||||
item = model.itemFromIndex(index)
|
||||
print("item1={}".format(item.text()))
|
||||
|
||||
if Type == "Color":
|
||||
|
||||
@@ -648,6 +649,7 @@ class MaterialsDelegate(QtGui.QStyledItemDelegate):
|
||||
else:
|
||||
|
||||
super(MaterialsDelegate, self).setEditorData(editor, index)
|
||||
print("item2={}".format(item.text()))
|
||||
|
||||
|
||||
ui = FreeCADGui.UiLoader()
|
||||
|
||||
@@ -729,6 +729,15 @@ checkvalueunit('FractureToughness', '25')
|
||||
checkvalueunit('Density', '1 kg/m^3')
|
||||
checkvalueunit('Density', '0 kg/m^3')
|
||||
|
||||
# syntax error in unit system, only the try: except in the checkvalueunit let it work
|
||||
checkvalueunit('ThermalConductivity', '0.02583 W/m/K')
|
||||
checkvalueunit('ThermalConductivity', '123abc456 W/m/K')
|
||||
checkvalueunit('ThermalConductivity', '25.83e−3 W/m/K')
|
||||
checkvalueunit('ThermalConductivity', '25.83e-3 W/m/K')
|
||||
from FreeCAD import Units
|
||||
Units.Quantity('25.83e−3 W/m/K')
|
||||
|
||||
|
||||
# test mat unit properties
|
||||
mat = {
|
||||
'Name': 'Concrete',
|
||||
|
||||
Reference in New Issue
Block a user