BIM: NativeIFC 2D support - section planes
This commit is contained in:
committed by
Yorik van Havre
parent
c0d452f6c5
commit
14585a760e
@@ -427,7 +427,7 @@ def get_svg(obj,
|
||||
# all the SVG strings from the contents of the group
|
||||
if hasattr(obj, "isDerivedFrom"):
|
||||
if (obj.isDerivedFrom("App::DocumentObjectGroup")
|
||||
or utils.get_type(obj) in ["Layer", "BuildingPart"]
|
||||
or utils.get_type(obj) in ["Layer", "BuildingPart", "IfcGroup"]
|
||||
or obj.isDerivedFrom("App::LinkGroup")
|
||||
or (obj.isDerivedFrom("App::Link")
|
||||
and obj.LinkedObject.isDerivedFrom("App::DocumentObjectGroup"))):
|
||||
@@ -546,7 +546,8 @@ def get_svg(obj,
|
||||
svg = _svg_shape(svg, obj, plane,
|
||||
fillstyle, pathdata, stroke, linewidth, lstyle)
|
||||
|
||||
elif utils.get_type(obj) in ["Dimension", "LinearDimension"]:
|
||||
elif (utils.get_type(obj) in ["Dimension", "LinearDimension"]
|
||||
or (utils.get_type(obj) == "IfcAnnotation" and obj.ObjectType == "DIMENSION")):
|
||||
svg = _svg_dimension(obj, plane, scale, linewidth, fontsize,
|
||||
stroke, tstroke, pointratio, techdraw, rotation)
|
||||
|
||||
@@ -690,7 +691,8 @@ def get_svg(obj,
|
||||
rotation, position, text,
|
||||
linespacing, justification)
|
||||
|
||||
elif utils.get_type(obj) in ["Annotation", "DraftText", "Text"]:
|
||||
elif (utils.get_type(obj) in ["Annotation", "DraftText", "Text"]
|
||||
or (utils.get_type(obj) == "IfcAnnotation" and obj.ObjectType == "TEXT")):
|
||||
# returns an svg representation of a document annotation
|
||||
if not App.GuiUp:
|
||||
_wrn("Export of texts to SVG is only available in GUI mode")
|
||||
|
||||
Reference in New Issue
Block a user