Rename core open_sheet, operator OpenSheet/bim.open_sheet to better reflect what it actually does, i.e. open_layout

This commit is contained in:
Stephen Boddy
2024-11-01 23:02:19 +00:00
parent 8b0e5097cc
commit 4cfc0bd9f3
2 changed files with 4 additions and 4 deletions
@@ -1446,8 +1446,8 @@ class AddSheet(bpy.types.Operator, tool.Ifc.Operator):
core.add_sheet(tool.Ifc, tool.Drawing, titleblock=context.scene.DocProperties.titleblock)
class OpenSheet(bpy.types.Operator, tool.Ifc.Operator):
bl_idname = "bim.open_sheet"
class OpenLayout(bpy.types.Operator, tool.Ifc.Operator):
bl_idname = "bim.open_layout"
bl_label = "Open Sheet Layout"
bl_options = {"REGISTER", "UNDO"}
@@ -1465,7 +1465,7 @@ class OpenSheet(bpy.types.Operator, tool.Ifc.Operator):
sheet = tool.Ifc.get().by_id(self.props.sheets[self.props.active_sheet_index].ifc_definition_id)
sheet_builder = sheeter.SheetBuilder()
sheet_builder.update_sheet_drawing_sizes(sheet)
core.open_sheet(tool.Drawing, sheet=sheet)
core.open_layout(tool.Drawing, sheet=sheet)
class AddDrawingToSheet(bpy.types.Operator, tool.Ifc.Operator):
+1 -1
View File
@@ -113,7 +113,7 @@ def regenerate_sheet(drawing: tool.Drawing, sheet: ifcopenshell.entity_instance)
drawing.delete_file(path_layout)
def open_sheet(drawing: tool.Drawing, sheet: ifcopenshell.entity_instance) -> None:
def open_layout(drawing: tool.Drawing, sheet: ifcopenshell.entity_instance) -> None:
drawing.open_layout_svg(drawing.get_document_uri(sheet, "LAYOUT"))