def unregister(): bpy.utils.unregister_class(AchmInfoMtMeshCustomMenuAdd) bpy.utils.unregister_class(AchmInfoMtMeshDecorationAdd) bpy.utils.unregister_class(achm_room_maker.AchmRoom) bpy.utils.unregister_class(achm_room_maker.AchmRoomGeneratorPanel) bpy.utils.unregister_class(achm_room_maker.AchmExportRoom) bpy.utils.unregister_class(achm_room_maker.AchmImportRoom) bpy.utils.unregister_class(achm_door_maker.AchmDoor) bpy.utils.unregister_class(achm_door_maker.AchmDoorObjectgeneratorpanel) bpy.utils.unregister_class(achm_window_maker.AchmWindows) bpy.utils.unregister_class( achm_window_maker.AchmWindowObjectgeneratorpanel) bpy.utils.unregister_class(achm_roof_maker.AchmRoof) bpy.utils.unregister_class(achm_column_maker.AchmColumn) bpy.utils.unregister_class(achm_stairs_maker.AchmStairs) bpy.utils.unregister_class(achm_kitchen_maker.AchmKitchen) bpy.utils.unregister_class(achm_kitchen_maker.AchmExportInventory) bpy.utils.unregister_class(achm_shelves_maker.AchmShelves) bpy.utils.unregister_class(achm_books_maker.AchmBooks) bpy.utils.unregister_class(achm_lamp_maker.AchmLamp) bpy.utils.unregister_class(achm_curtain_maker.AchmRoller) bpy.utils.unregister_class(achm_curtain_maker.AchmJapan) bpy.utils.unregister_class(achm_venetian_maker.AchmVenetian) bpy.utils.unregister_class( achm_venetian_maker.AchmVenetianObjectgeneratorpanel) bpy.utils.unregister_class(achm_main_panel.ArchimeshMainPanel) bpy.utils.unregister_class(achm_main_panel.AchmHoleAction) bpy.utils.unregister_class(achm_main_panel.AchmPencilAction) bpy.utils.unregister_class(achm_main_panel.AchmRunHintDisplayButton) bpy.utils.unregister_class(achm_window_panel.AchmWinPanel) bpy.utils.unregister_class(achm_window_panel.AchmWindowEditPanel) bpy.utils.unregister_class(Archi_Pref) INFO_MT_mesh_add.remove(AchmMenu_func) # Remove properties del Scene.archimesh_select_only del Scene.archimesh_ceiling del Scene.archimesh_floor del Scene.archimesh_merge del Scene.archimesh_text_color del Scene.archimesh_walltext_color del Scene.archimesh_font_size del Scene.archimesh_wfont_size del Scene.archimesh_hint_space del Scene.archimesh_gl_measure del Scene.archimesh_gl_name del Scene.archimesh_gl_ghost # remove OpenGL data achm_main_panel.AchmRunHintDisplayButton.handle_remove( achm_main_panel.AchmRunHintDisplayButton, bpy.context) wm = bpy.context.window_manager p = 'archimesh_run_opengl' if p in wm: del wm[p]
def unregister(): bpy.utils.unregister_class(AchmInfoMtMeshCustomMenuAdd) bpy.utils.unregister_class(AchmInfoMtMeshDecorationAdd) bpy.utils.unregister_class(achm_room_maker.AchmRoom) bpy.utils.unregister_class(achm_room_maker.AchmRoomGeneratorPanel) bpy.utils.unregister_class(achm_room_maker.AchmExportRoom) bpy.utils.unregister_class(achm_room_maker.AchmImportRoom) bpy.utils.unregister_class(achm_door_maker.AchmDoor) bpy.utils.unregister_class(achm_door_maker.AchmDoorObjectgeneratorpanel) bpy.utils.unregister_class(achm_window_maker.AchmWindows) bpy.utils.unregister_class(achm_window_maker.AchmWindowObjectgeneratorpanel) bpy.utils.unregister_class(achm_roof_maker.AchmRoof) bpy.utils.unregister_class(achm_column_maker.AchmColumn) bpy.utils.unregister_class(achm_stairs_maker.AchmStairs) bpy.utils.unregister_class(achm_kitchen_maker.AchmKitchen) bpy.utils.unregister_class(achm_kitchen_maker.AchmExportInventory) bpy.utils.unregister_class(achm_shelves_maker.AchmShelves) bpy.utils.unregister_class(achm_books_maker.AchmBooks) bpy.utils.unregister_class(achm_lamp_maker.AchmLamp) bpy.utils.unregister_class(achm_curtain_maker.AchmRoller) bpy.utils.unregister_class(achm_curtain_maker.AchmJapan) bpy.utils.unregister_class(achm_venetian_maker.AchmVenetian) bpy.utils.unregister_class(achm_venetian_maker.AchmVenetianObjectgeneratorpanel) bpy.utils.unregister_class(achm_main_panel.ArchimeshMainPanel) bpy.utils.unregister_class(achm_main_panel.AchmHoleAction) bpy.utils.unregister_class(achm_main_panel.AchmPencilAction) bpy.utils.unregister_class(achm_main_panel.AchmRunHintDisplayButton) bpy.utils.unregister_class(achm_window_panel.AchmWinPanel) bpy.utils.unregister_class(achm_window_panel.AchmWindowEditPanel) bpy.utils.unregister_class(Archi_Pref) INFO_MT_mesh_add.remove(AchmMenu_func) # Remove properties del Scene.archimesh_select_only del Scene.archimesh_ceiling del Scene.archimesh_floor del Scene.archimesh_merge del Scene.archimesh_text_color del Scene.archimesh_walltext_color del Scene.archimesh_font_size del Scene.archimesh_wfont_size del Scene.archimesh_hint_space del Scene.archimesh_gl_measure del Scene.archimesh_gl_name del Scene.archimesh_gl_ghost # remove OpenGL data achm_main_panel.AchmRunHintDisplayButton.handle_remove(achm_main_panel.AchmRunHintDisplayButton, bpy.context) wm = bpy.context.window_manager p = 'archimesh_run_opengl' if p in wm: del wm[p]
def register(): bpy.utils.register_class(AchmInfoMtMeshCustomMenuAdd) bpy.utils.register_class(AchmInfoMtMeshDecorationAdd) bpy.utils.register_class(achm_room_maker.AchmRoom) bpy.utils.register_class(achm_room_maker.AchmRoomGeneratorPanel) bpy.utils.register_class(achm_room_maker.AchmExportRoom) bpy.utils.register_class(achm_room_maker.AchmImportRoom) bpy.utils.register_class(achm_door_maker.AchmDoor) bpy.utils.register_class(achm_door_maker.AchmDoorObjectgeneratorpanel) bpy.utils.register_class(achm_window_maker.AchmWindows) bpy.utils.register_class(achm_window_maker.AchmWindowObjectgeneratorpanel) bpy.utils.register_class(achm_roof_maker.AchmRoof) bpy.utils.register_class(achm_column_maker.AchmColumn) bpy.utils.register_class(achm_stairs_maker.AchmStairs) bpy.utils.register_class(achm_kitchen_maker.AchmKitchen) bpy.utils.register_class(achm_kitchen_maker.AchmExportInventory) bpy.utils.register_class(achm_shelves_maker.AchmShelves) bpy.utils.register_class(achm_books_maker.AchmBooks) bpy.utils.register_class(achm_lamp_maker.AchmLamp) bpy.utils.register_class(achm_curtain_maker.AchmRoller) bpy.utils.register_class(achm_curtain_maker.AchmJapan) bpy.utils.register_class(achm_venetian_maker.AchmVenetian) bpy.utils.register_class( achm_venetian_maker.AchmVenetianObjectgeneratorpanel) bpy.utils.register_class(achm_main_panel.ArchimeshMainPanel) bpy.utils.register_class(achm_main_panel.AchmHoleAction) bpy.utils.register_class(achm_main_panel.AchmPencilAction) bpy.utils.register_class(achm_main_panel.AchmRunHintDisplayButton) bpy.utils.register_class(achm_window_panel.AchmWinPanel) bpy.utils.register_class(achm_window_panel.AchmWindowEditPanel) bpy.utils.register_class(Archi_Pref) INFO_MT_mesh_add.append(AchmMenu_func) update_panel(None, bpy.context) # Define properties Scene.archimesh_select_only = BoolProperty( name="Only selected", description="Apply auto holes only to selected objects", default=False, ) Scene.archimesh_ceiling = BoolProperty( name="Ceiling", description="Create a ceiling", default=False, ) Scene.archimesh_floor = BoolProperty( name="Floor", description="Create a floor automatically", default=False, ) Scene.archimesh_merge = BoolProperty( name="Close walls", description="Close walls to create a full closed room", default=False, ) Scene.archimesh_text_color = FloatVectorProperty( name="Hint color", description="Color for the text and lines", default=(0.173, 0.545, 1.0, 1.0), min=0.1, max=1, subtype='COLOR', size=4, ) Scene.archimesh_walltext_color = FloatVectorProperty( name="Hint color", description="Color for the wall label", default=(1, 0.8, 0.1, 1.0), min=0.1, max=1, subtype='COLOR', size=4, ) Scene.archimesh_font_size = IntProperty( name="Text Size", description="Text size for hints", default=14, min=10, max=150, ) Scene.archimesh_wfont_size = IntProperty( name="Text Size", description="Text size for wall labels", default=16, min=10, max=150, ) Scene.archimesh_hint_space = FloatProperty( name='Separation', min=0, max=5, default=0.1, precision=2, description='Distance from object to display hint', ) Scene.archimesh_gl_measure = BoolProperty( name="Measures", description="Display measures", default=True, ) Scene.archimesh_gl_name = BoolProperty( name="Names", description="Display names", default=True, ) Scene.archimesh_gl_ghost = BoolProperty( name="All", description="Display measures for all objects," " not only selected", default=True, ) # OpenGL flag wm = WindowManager # register internal property wm.archimesh_run_opengl = BoolProperty(default=False)
def register(): bpy.utils.register_class(AchmInfoMtMeshCustomMenuAdd) bpy.utils.register_class(AchmInfoMtMeshDecorationAdd) bpy.utils.register_class(achm_room_maker.AchmRoom) bpy.utils.register_class(achm_room_maker.AchmRoomGeneratorPanel) bpy.utils.register_class(achm_room_maker.AchmExportRoom) bpy.utils.register_class(achm_room_maker.AchmImportRoom) bpy.utils.register_class(achm_door_maker.AchmDoor) bpy.utils.register_class(achm_door_maker.AchmDoorObjectgeneratorpanel) bpy.utils.register_class(achm_window_maker.AchmWindows) bpy.utils.register_class(achm_window_maker.AchmWindowObjectgeneratorpanel) bpy.utils.register_class(achm_roof_maker.AchmRoof) bpy.utils.register_class(achm_column_maker.AchmColumn) bpy.utils.register_class(achm_stairs_maker.AchmStairs) bpy.utils.register_class(achm_kitchen_maker.AchmKitchen) bpy.utils.register_class(achm_kitchen_maker.AchmExportInventory) bpy.utils.register_class(achm_shelves_maker.AchmShelves) bpy.utils.register_class(achm_books_maker.AchmBooks) bpy.utils.register_class(achm_lamp_maker.AchmLamp) bpy.utils.register_class(achm_curtain_maker.AchmRoller) bpy.utils.register_class(achm_curtain_maker.AchmJapan) bpy.utils.register_class(achm_venetian_maker.AchmVenetian) bpy.utils.register_class(achm_venetian_maker.AchmVenetianObjectgeneratorpanel) bpy.utils.register_class(achm_main_panel.ArchimeshMainPanel) bpy.utils.register_class(achm_main_panel.AchmHoleAction) bpy.utils.register_class(achm_main_panel.AchmPencilAction) bpy.utils.register_class(achm_main_panel.AchmRunHintDisplayButton) bpy.utils.register_class(achm_window_panel.AchmWinPanel) bpy.utils.register_class(achm_window_panel.AchmWindowEditPanel) bpy.utils.register_class(Archi_Pref) INFO_MT_mesh_add.append(AchmMenu_func) update_panel(None, bpy.context) # Define properties Scene.archimesh_select_only = BoolProperty( name="Only selected", description="Apply auto holes only to selected objects", default=False, ) Scene.archimesh_ceiling = BoolProperty( name="Ceiling", description="Create a ceiling", default=False, ) Scene.archimesh_floor = BoolProperty( name="Floor", description="Create a floor automatically", default=False, ) Scene.archimesh_merge = BoolProperty( name="Close walls", description="Close walls to create a full closed room", default=False, ) Scene.archimesh_text_color = FloatVectorProperty( name="Hint color", description="Color for the text and lines", default=(0.173, 0.545, 1.0, 1.0), min=0.1, max=1, subtype='COLOR', size=4, ) Scene.archimesh_walltext_color = FloatVectorProperty( name="Hint color", description="Color for the wall label", default=(1, 0.8, 0.1, 1.0), min=0.1, max=1, subtype='COLOR', size=4, ) Scene.archimesh_font_size = IntProperty( name="Text Size", description="Text size for hints", default=14, min=10, max=150, ) Scene.archimesh_wfont_size = IntProperty( name="Text Size", description="Text size for wall labels", default=16, min=10, max=150, ) Scene.archimesh_hint_space = FloatProperty( name='Separation', min=0, max=5, default=0.1, precision=2, description='Distance from object to display hint', ) Scene.archimesh_gl_measure = BoolProperty( name="Measures", description="Display measures", default=True, ) Scene.archimesh_gl_name = BoolProperty( name="Names", description="Display names", default=True, ) Scene.archimesh_gl_ghost = BoolProperty( name="All", description="Display measures for all objects," " not only selected", default=True, ) # OpenGL flag wm = WindowManager # register internal property wm.archimesh_run_opengl = BoolProperty(default=False)
def unregister(): for module_class in modules: bpy.utils.unregister_class(module_class) INFO_MT_mesh_add.remove(ArchLabMeshMenu_func)
def register(): for module_class in modules: bpy.utils.register_class(module_class) INFO_MT_mesh_add.append(ArchLabMeshMenu_func)