def setSliceElementZ(decimalPlacesCarried, sliceElement, sliceElementIndex, z):
 roundedZ = euclidean.getRoundedToPlacesString(decimalPlacesCarried, z)
 idValue = ('z:%s' % roundedZ)
 sliceElement.attributeDictionary['id'] = idValue
 textElement = sliceElement.getFirstChildWithClassName('text')
 textElement.text = ('Layer %s, %s' % (sliceElementIndex, idValue))

def setSliceElementZ ( decimalPlacesCarried , sliceElement , sliceElementIndex , z ) : roundedZ = euclidean . getRoundedToPlacesString ( decimalPlacesCarried , z ) idValue = ( 'z:%s' % roundedZ ) sliceElement . attributeDictionary [ 'id' ] = idValue textElement = sliceElement . getFirstChildWithClassName ( 'text' ) textElement . text = ( 'Layer %s, %s' % ( sliceElementIndex , idValue ) )
set the slice element z .