mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-10 01:41:57 +00:00
See #5269. Minor tweak to show warning if manual mode changes detected.
This commit is contained in:
+40
-25
@@ -421,34 +421,49 @@ class BIM_PT_tabs(Panel):
|
||||
|
||||
row = self.layout.row(align=True)
|
||||
row.prop(aprops, "tab", text="")
|
||||
|
||||
if bonsai.REINSTALLED_BBIM_VERSION:
|
||||
box = self.layout.box()
|
||||
box.alert = True
|
||||
|
||||
box.label(text="Bonsai requires Blender to restart.", icon="ERROR")
|
||||
box.label(text="Bonsai was reinstalled in the current session:")
|
||||
box.label(text=f"{bonsai.FIRST_INSTALLED_BBIM_VERSION} -> {bonsai.REINSTALLED_BBIM_VERSION}")
|
||||
box.label(text="Please restart Blender to avoid potential issues.")
|
||||
box.operator("bim.restart_blender", text="Restart Blender", icon="BLENDER")
|
||||
|
||||
if bonsai.last_error:
|
||||
box = self.layout.box()
|
||||
box.alert = True
|
||||
row = box.row(align=True)
|
||||
row.label(text="Bonsai experienced an error :(", icon="ERROR")
|
||||
row.operator("bim.close_error", text="", icon="CANCEL")
|
||||
if platform.system() == "Windows":
|
||||
box.operator("wm.console_toggle", text="View the console for full logs.", icon="CONSOLE")
|
||||
else:
|
||||
box.label(text="View the console for full logs.", icon="CONSOLE")
|
||||
box.operator("bim.copy_debug_information", text="Copy Error Message To Clipboard")
|
||||
op = box.operator("bim.open_uri", text="How Can I Fix This?")
|
||||
op.uri = "https://docs.bonsaibim.org/users/troubleshooting.html"
|
||||
|
||||
except:
|
||||
pass # Prior to load_post, we may not have any area properties setup
|
||||
|
||||
if bonsai.REINSTALLED_BBIM_VERSION:
|
||||
box = self.layout.box()
|
||||
box.alert = True
|
||||
box.label(text="Bonsai requires Blender to restart.", icon="ERROR")
|
||||
box.label(text="Bonsai was reinstalled in the current session:")
|
||||
box.label(text=f"{bonsai.FIRST_INSTALLED_BBIM_VERSION} -> {bonsai.REINSTALLED_BBIM_VERSION}")
|
||||
box.operator("bim.restart_blender", text="Restart Blender", icon="BLENDER")
|
||||
|
||||
if bonsai.last_error:
|
||||
box = self.layout.box()
|
||||
box.alert = True
|
||||
row = box.row(align=True)
|
||||
row.label(text="Bonsai experienced an error :(", icon="ERROR")
|
||||
row.operator("bim.close_error", text="", icon="CANCEL")
|
||||
if platform.system() == "Windows":
|
||||
box.operator("wm.console_toggle", text="View the console for full logs.", icon="CONSOLE")
|
||||
else:
|
||||
box.label(text="View the console for full logs.", icon="CONSOLE")
|
||||
box.operator("bim.copy_debug_information", text="Copy Error Message To Clipboard")
|
||||
op = box.operator("bim.open_uri", text="How Can I Fix This?")
|
||||
op.uri = "https://docs.bonsaibim.org/users/troubleshooting.html"
|
||||
|
||||
props = context.scene.BIMProperties
|
||||
if (tool.Ifc.get() or props.ifc_file) and props.has_blend_warning:
|
||||
box = self.layout.box()
|
||||
box.alert = True
|
||||
row = box.row(align=True)
|
||||
row.label(text="Your model may be outdated", icon="ERROR")
|
||||
op = row.operator("bim.open_uri", text="", icon="QUESTION")
|
||||
op.uri = "https://docs.bonsaibim.org/users/troubleshooting.html#saving-and-loading-blend-files"
|
||||
row.operator("bim.close_blend_warning", text="", icon="CANCEL")
|
||||
|
||||
if context.mode != context.scene.BIMGeometryProperties.mode:
|
||||
box = self.layout.box()
|
||||
box.alert = True
|
||||
row = box.row(align=True)
|
||||
row.label(text="Geometry changes will be lost", icon="ERROR")
|
||||
op = row.operator("bim.open_uri", text="", icon="QUESTION")
|
||||
op.uri = "https://docs.bonsaibim.org/users/troubleshooting.html#incompatible-blender-features"
|
||||
|
||||
def draw_tab_entry(self, row, icon, tab_name, enabled=True, highlight=False):
|
||||
tab_entry = row.row(align=True)
|
||||
tab_entry.operator("bim.set_tab", text="", emboss=highlight, icon=icon, depress=True).tab = tab_name
|
||||
|
||||
@@ -58,10 +58,10 @@ can `report a bug <https://github.com/ifcopenshell/ifcopenshell/issues>`_ or
|
||||
with factory settings.
|
||||
|
||||
To quickly test in a clean environment, first :ref:`find your Blender
|
||||
configuration folder<users/troubleshooting:Where is the add-on
|
||||
configuration folder<guides/troubleshooting:Where is the add-on
|
||||
installed?>`. Rename the folder from ``X.XX`` to something else like
|
||||
``X.XX_backup``, then restart Blender and try follow the :doc:`installation
|
||||
instructions</users/quickstart/installation>` again.
|
||||
instructions</quickstart/installation>` again.
|
||||
|
||||
If this fixes your issue, consider disabling other add-ons one by one until
|
||||
you find a conflict as a next step to isolating the issue.
|
||||
@@ -100,6 +100,23 @@ create unpredictable, and sometimes unrecoverable errors.
|
||||
|
||||
To avoid this issue, only open and save IFCs.
|
||||
|
||||
Incompatible Blender features
|
||||
-----------------------------
|
||||
|
||||
Blender offers features such as animation, sculpting, modifiers, and more that
|
||||
are not available in IFC. As :ref:`Bonsai uses IFC as its native data
|
||||
store<guides/troubleshooting:Saving and loading blend files>`, using these
|
||||
incompatible features may result in data loss.
|
||||
|
||||
1. **Manual geometry editing**. Manually changing the mode to Edit or Object
|
||||
mode in the :menuselection:`3D Viewport` top left dropdown menu. This
|
||||
changes the Blender mesh editing mode, but any changes may be incompatible
|
||||
with the IFC geometry. This is because IFC geometry may not be a mesh, or
|
||||
have parametric constraints. Any changes made in this manner may have
|
||||
unpredictable effects and changes may be discarded. Instead, always use the
|
||||
:kbd:`Tab` key to toggle object editing, or use the IFC Object / Edit mode
|
||||
toggle in the top right of the :menuselection:`3D Viewport`.
|
||||
|
||||
Where is the add-on installed?
|
||||
------------------------------
|
||||
|
||||
|
||||
Reference in New Issue
Block a user