mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-22 20:02:30 +00:00
Minor fixes.
This commit is contained in:
@@ -1887,10 +1887,11 @@ class IfcImportSettings:
|
|||||||
@staticmethod
|
@staticmethod
|
||||||
def factory(context, input_file, logger):
|
def factory(context, input_file, logger):
|
||||||
scene_bim = context.scene.BIMProperties
|
scene_bim = context.scene.BIMProperties
|
||||||
|
scene_diff = context.scene.DiffProperties
|
||||||
settings = IfcImportSettings()
|
settings = IfcImportSettings()
|
||||||
settings.input_file = input_file
|
settings.input_file = input_file
|
||||||
settings.logger = logger
|
settings.logger = logger
|
||||||
settings.diff_file = scene_bim.diff_json_file
|
settings.diff_file = scene_diff.diff_json_file
|
||||||
settings.ifc_import_filter = scene_bim.ifc_import_filter
|
settings.ifc_import_filter = scene_bim.ifc_import_filter
|
||||||
settings.ifc_selector = scene_bim.ifc_selector
|
settings.ifc_selector = scene_bim.ifc_selector
|
||||||
settings.should_import_type_representations = scene_bim.import_should_import_type_representations
|
settings.should_import_type_representations = scene_bim.import_should_import_type_representations
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ from blenderbim.bim.module.aggregate.data import Data
|
|||||||
|
|
||||||
|
|
||||||
class BIM_PT_aggregate(Panel):
|
class BIM_PT_aggregate(Panel):
|
||||||
bl_label = "IFC Aggregation"
|
bl_label = "IFC Aggregates"
|
||||||
bl_idname = "BIM_PT_aggregate"
|
bl_idname = "BIM_PT_aggregate"
|
||||||
bl_space_type = "PROPERTIES"
|
bl_space_type = "PROPERTIES"
|
||||||
bl_region_type = "WINDOW"
|
bl_region_type = "WINDOW"
|
||||||
@@ -38,7 +38,7 @@ class BIM_PT_aggregate(Panel):
|
|||||||
Data.products[props.ifc_definition_id]["type"], Data.products[props.ifc_definition_id]["Name"]
|
Data.products[props.ifc_definition_id]["type"], Data.products[props.ifc_definition_id]["Name"]
|
||||||
)
|
)
|
||||||
if name == "None/None":
|
if name == "None/None":
|
||||||
name = "This object is not part of an aggregation"
|
name = "No Aggregate Found"
|
||||||
row.label(text=name)
|
row.label(text=name)
|
||||||
row.operator("bim.enable_editing_aggregate", icon="GREASEPENCIL", text="")
|
row.operator("bim.enable_editing_aggregate", icon="GREASEPENCIL", text="")
|
||||||
row.operator("bim.add_aggregate", icon="ADD", text="")
|
row.operator("bim.add_aggregate", icon="ADD", text="")
|
||||||
|
|||||||
@@ -18,4 +18,3 @@ class DiffProperties(PropertyGroup):
|
|||||||
diff_old_file: StringProperty(default="", name="Diff Old IFC File")
|
diff_old_file: StringProperty(default="", name="Diff Old IFC File")
|
||||||
diff_new_file: StringProperty(default="", name="Diff New IFC File")
|
diff_new_file: StringProperty(default="", name="Diff New IFC File")
|
||||||
diff_relationships: StringProperty(default="", name="Diff Relationships")
|
diff_relationships: StringProperty(default="", name="Diff Relationships")
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
import bpy
|
import bpy
|
||||||
from bpy.types import Panel
|
from bpy.types import Panel
|
||||||
from blenderbim.bim.module.geometry.data import Data
|
from blenderbim.bim.module.geometry.data import Data
|
||||||
|
from blenderbim.bim.ifc import IfcStore
|
||||||
|
|
||||||
|
|
||||||
class BIM_PT_representations(Panel):
|
class BIM_PT_representations(Panel):
|
||||||
@@ -11,6 +12,10 @@ class BIM_PT_representations(Panel):
|
|||||||
bl_region_type = "WINDOW"
|
bl_region_type = "WINDOW"
|
||||||
bl_context = "object"
|
bl_context = "object"
|
||||||
|
|
||||||
|
@classmethod
|
||||||
|
def poll(cls, context):
|
||||||
|
return IfcStore.get_file()
|
||||||
|
|
||||||
def draw(self, context):
|
def draw(self, context):
|
||||||
layout = self.layout
|
layout = self.layout
|
||||||
props = context.active_object.BIMObjectProperties
|
props = context.active_object.BIMObjectProperties
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ class BIM_PT_project(Panel):
|
|||||||
props = context.scene.BIMProperties
|
props = context.scene.BIMProperties
|
||||||
row = self.layout.row(align=True)
|
row = self.layout.row(align=True)
|
||||||
row.label(text="IFC File", icon="FILE")
|
row.label(text="IFC File", icon="FILE")
|
||||||
row.label(text=os.path.basename(props.ifc_file))
|
row.label(text=os.path.basename(props.ifc_file) or "No File Found")
|
||||||
|
|
||||||
row = self.layout.row(align=True)
|
row = self.layout.row(align=True)
|
||||||
row.label(text="IFC Schema", icon="FILE_CACHE")
|
row.label(text="IFC Schema", icon="FILE_CACHE")
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
import bpy
|
import bpy
|
||||||
from bpy.types import Panel
|
from bpy.types import Panel
|
||||||
from blenderbim.bim.module.void.data import Data
|
from blenderbim.bim.module.void.data import Data
|
||||||
|
from blenderbim.bim.ifc import IfcStore
|
||||||
|
|
||||||
|
|
||||||
class BIM_PT_voids(Panel):
|
class BIM_PT_voids(Panel):
|
||||||
@@ -11,6 +12,10 @@ class BIM_PT_voids(Panel):
|
|||||||
bl_region_type = "WINDOW"
|
bl_region_type = "WINDOW"
|
||||||
bl_context = "object"
|
bl_context = "object"
|
||||||
|
|
||||||
|
@classmethod
|
||||||
|
def poll(cls, context):
|
||||||
|
return IfcStore.get_file()
|
||||||
|
|
||||||
def draw(self, context):
|
def draw(self, context):
|
||||||
props = context.active_object.BIMObjectProperties
|
props = context.active_object.BIMObjectProperties
|
||||||
if props.ifc_definition_id not in Data.products:
|
if props.ifc_definition_id not in Data.products:
|
||||||
|
|||||||
@@ -944,7 +944,6 @@ class BIM_PT_mvd(Panel):
|
|||||||
|
|
||||||
class BIM_UL_generic(bpy.types.UIList):
|
class BIM_UL_generic(bpy.types.UIList):
|
||||||
def draw_item(self, context, layout, data, item, icon, active_data, active_propname):
|
def draw_item(self, context, layout, data, item, icon, active_data, active_propname):
|
||||||
ob = data
|
|
||||||
if item:
|
if item:
|
||||||
layout.prop(item, "name", text="", emboss=False)
|
layout.prop(item, "name", text="", emboss=False)
|
||||||
else:
|
else:
|
||||||
|
|||||||
Reference in New Issue
Block a user