Fixing bug with changing text size #3159

Bug appeared after 046940f but it was there before - it was just kind of compensated by the other bug.
Because of that bug blender text size value was reupdated before saving it to pset therefore pset never received a new value.

Also added some refactor, planned to write some test to get this error covered.
This commit is contained in:
Andrej730
2023-05-16 17:05:12 +05:00
parent 87dba7c066
commit ae0ae76ee6
5 changed files with 20 additions and 16 deletions
@@ -759,12 +759,7 @@ class Drawing(blenderbim.core.tool.Drawing):
props = obj.BIMTextProperties
literals = cls.get_text_literal(obj, return_list=True)
if not literals:
props.literals.clear()
return
cls.import_text_attributes(obj)
for i, literal in enumerate(literals):
product = cls.get_assigned_product(tool.Ifc.get_entity(obj))
props.literals[i].value = cls.replace_text_literal_variables(literal.Literal, product)