mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-09 05:46:51 +00:00
Filter drawing search to only match DRAWING annotations
This commit is contained in:
@@ -479,10 +479,12 @@ class BIM_PT_sheets(Panel):
|
|||||||
drawingnamesvg = active_sheet.name
|
drawingnamesvg = active_sheet.name
|
||||||
drawingname = drawingnamesvg.split(".svg")[0]
|
drawingname = drawingnamesvg.split(".svg")[0]
|
||||||
ifc_file = tool.Ifc.get()
|
ifc_file = tool.Ifc.get()
|
||||||
ifc_annotations = ifc_file.by_type("IfcAnnotation")
|
|
||||||
drawingid = None
|
drawingid = None
|
||||||
|
|
||||||
for annotation in ifc_annotations:
|
for annotation in ifc_file.by_type("IfcAnnotation"):
|
||||||
|
if annotation.ObjectType != "DRAWING":
|
||||||
|
continue
|
||||||
|
|
||||||
Annotation_Name = annotation.Name.replace(",", "") # Remove commas
|
Annotation_Name = annotation.Name.replace(",", "") # Remove commas
|
||||||
if Annotation_Name == drawingname:
|
if Annotation_Name == drawingname:
|
||||||
drawingid = annotation.id()
|
drawingid = annotation.id()
|
||||||
|
|||||||
Reference in New Issue
Block a user