mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-09 17:31:45 +00:00
Tool header and side panel improvements (#5500)
* Conditions added to show Edit vs Create for each Tool * Void conditions revised Apply Voids now only show when number of selected objects ==2, and one of them is a void * Conditions added to show create vs edit for each tool example: to edit a wall -> the wall tool must be the active tool and a wall must be selected, to add a wall -> the wall tool must be the active tool and a wall must not be selected * Extend wall to slab icons added dark and light mode versions added * Reset vertex icons added dark and light mode version added * Type Manager Preview added --------- Co-authored-by: tim <tjrhyder@gmail.com> Co-authored-by: Dion Moult <dion@thinkmoult.com>
This commit is contained in:
Binary file not shown.
|
After Width: | Height: | Size: 301 B |
Binary file not shown.
|
After Width: | Height: | Size: 1.1 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 336 B |
Binary file not shown.
|
After Width: | Height: | Size: 1.3 KiB |
@@ -58,6 +58,7 @@ class AuthoringData:
|
||||
cls.data["ifc_classes"] = cls.ifc_classes()
|
||||
cls.data["relating_type_id"] = cls.relating_type_id() # only after .ifc_classes()
|
||||
cls.data["relating_type_name"] = cls.relating_type_name() # only after .relating_type_id()
|
||||
cls.data["relating_type_description"] = cls.relating_type_description() # only after .relating_type_id()
|
||||
cls.data["predefined_type"] = cls.predefined_type() # only after .relating_type_id()
|
||||
|
||||
# only after .ifc_classes()
|
||||
@@ -240,6 +241,11 @@ class AuthoringData:
|
||||
relating_type_id = relating_type_id_data[0][0]
|
||||
if relating_type_id:
|
||||
return tool.Ifc.get().by_id(int(relating_type_id)).Name or "Unnamed"
|
||||
|
||||
@classmethod
|
||||
def relating_type_description(cls):
|
||||
if relating_type_id := cls.props.relating_type_id:
|
||||
return tool.Ifc.get().by_id(int(relating_type_id)).Description or "No description"
|
||||
|
||||
@classmethod
|
||||
def predefined_type(cls):
|
||||
|
||||
@@ -107,7 +107,6 @@ class BimTool(WorkSpaceTool):
|
||||
|
||||
@classmethod
|
||||
def draw_settings(cls, context, layout, ws_tool):
|
||||
# Unlike operators, Blender doesn't treat workspace tools as a class, so we'll create our own.
|
||||
if context.scene.BIMGeometryProperties.mode == "ITEM":
|
||||
EditItemUI.draw(context, layout)
|
||||
elif context.active_object and context.selected_objects:
|
||||
|
||||
@@ -29,14 +29,14 @@
|
||||
inkscape:document-units="px"
|
||||
showgrid="true"
|
||||
inkscape:zoom="22.627417"
|
||||
inkscape:cx="15.224893"
|
||||
inkscape:cy="23.798563"
|
||||
inkscape:window-width="2328"
|
||||
inkscape:cx="14.097941"
|
||||
inkscape:cy="9.7006212"
|
||||
inkscape:window-width="2326"
|
||||
inkscape:window-height="1555"
|
||||
inkscape:window-x="590"
|
||||
inkscape:window-y="45"
|
||||
inkscape:window-x="592"
|
||||
inkscape:window-y="25"
|
||||
inkscape:window-maximized="0"
|
||||
inkscape:current-layer="g59575"
|
||||
inkscape:current-layer="g1622"
|
||||
showguides="true"><inkscape:grid
|
||||
type="axonomgrid"
|
||||
id="grid5114"
|
||||
@@ -377,6 +377,65 @@
|
||||
d="M 6.3376284,4.233333 6.7182939,5.7245206 8.1379048,6.1037675 6.6467171,6.4844329 6.2674703,7.9040438 5.8868048,6.4128561 4.4671939,6.0336093 5.9583816,5.6529438 Z"
|
||||
transform="matrix(0.5045571,0,0,0.5045571,4.360629,1.715138)" /></g><g
|
||||
inkscape:groupmode="layer"
|
||||
id="g1622"
|
||||
inkscape:label="reset_vertex"
|
||||
style="display:inline;stroke-width:0.529167;stroke-dasharray:none"><g
|
||||
id="g1635"
|
||||
transform="matrix(-1,0,0,1,8.4666676,0)"><path
|
||||
id="path1612"
|
||||
style="color:#000000;fill:#00d27b;stroke-linejoin:round;stroke-miterlimit:0;-inkscape-stroke:none;paint-order:stroke fill markers"
|
||||
d="m 4.2322998,0.79271647 c -1.8962705,0 -3.43958333,1.54331273 -3.43958333,3.43958333 0,1.8962705 1.54331283,3.4416504 3.43958333,3.4416504 0.5526674,0 1.0754694,-0.131382 1.5389242,-0.3643189 L 5.5185262,6.8032023 c -0.386732,0.1933362 -0.8233795,0.3023071 -1.2862264,0.3023071 -1.5901009,0 -2.8726929,-1.2831086 -2.8726929,-2.8732096 0,-1.5901011 1.282592,-2.8726929 2.8726929,-2.8726929 1.2342128,0 2.2829816,0.7728658 2.6907918,1.8624187 l 0.5963461,-0.00879 C 7.0835409,1.8128107 5.7739374,0.79271647 4.2322998,0.79271647 Z"
|
||||
inkscape:label="circle-path" /><path
|
||||
style="display:inline;fill:#000000;fill-opacity:0;stroke:#00d27b;stroke-width:0.440014;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1;paint-order:stroke fill markers"
|
||||
d="M 5.5116727,3.2431535 H 7.4529091 V 1.3019173"
|
||||
id="path1614"
|
||||
inkscape:label="Arrow_head 1" /><path
|
||||
sodipodi:type="star"
|
||||
style="fill:#ffffff;fill-opacity:1;stroke:#00d27b;stroke-width:0;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:0;stroke-dasharray:none;stroke-opacity:1;paint-order:stroke fill markers"
|
||||
id="path1616"
|
||||
inkscape:flatsided="false"
|
||||
sodipodi:sides="4"
|
||||
sodipodi:cx="6.3025494"
|
||||
sodipodi:cy="6.0686884"
|
||||
sodipodi:r1="1.8356906"
|
||||
sodipodi:r2="0.5397175"
|
||||
sodipodi:arg1="-1.5516857"
|
||||
sodipodi:arg2="-0.69148437"
|
||||
inkscape:rounded="0"
|
||||
inkscape:randomized="0"
|
||||
d="M 6.3376284,4.233333 6.7182939,5.7245206 8.1379048,6.1037675 6.6467171,6.4844329 6.2674703,7.9040438 5.8868048,6.4128561 4.4671939,6.0336093 5.9583816,5.6529438 Z"
|
||||
transform="matrix(0.72079571,0,0,0.72079571,0.11602734,-0.22857096)" /><path
|
||||
sodipodi:type="star"
|
||||
style="display:inline;fill:#ffffff;fill-opacity:1;stroke:#00d27b;stroke-width:0;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:0;stroke-dasharray:none;stroke-opacity:1;paint-order:stroke fill markers"
|
||||
id="path1618"
|
||||
inkscape:flatsided="false"
|
||||
sodipodi:sides="4"
|
||||
sodipodi:cx="6.3025494"
|
||||
sodipodi:cy="6.0686884"
|
||||
sodipodi:r1="1.8356906"
|
||||
sodipodi:r2="0.5397175"
|
||||
sodipodi:arg1="-1.5516857"
|
||||
sodipodi:arg2="-0.69148437"
|
||||
inkscape:rounded="0"
|
||||
inkscape:randomized="0"
|
||||
d="M 6.3376284,4.233333 6.7182939,5.7245206 8.1379048,6.1037675 6.6467171,6.4844329 6.2674703,7.9040438 5.8868048,6.4128561 4.4671939,6.0336093 5.9583816,5.6529438 Z"
|
||||
transform="matrix(1.009114,0,0,1.009114,-0.07417958,-0.06494846)" /><path
|
||||
sodipodi:type="star"
|
||||
style="display:inline;fill:#ffffff;fill-opacity:1;stroke:#00d27b;stroke-width:0;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:0;stroke-dasharray:none;stroke-opacity:1;paint-order:stroke fill markers"
|
||||
id="path1620"
|
||||
inkscape:flatsided="false"
|
||||
sodipodi:sides="4"
|
||||
sodipodi:cx="6.3025494"
|
||||
sodipodi:cy="6.0686884"
|
||||
sodipodi:r1="1.8356906"
|
||||
sodipodi:r2="0.5397175"
|
||||
sodipodi:arg1="-1.5516857"
|
||||
sodipodi:arg2="-0.69148437"
|
||||
inkscape:rounded="0"
|
||||
inkscape:randomized="0"
|
||||
d="M 6.3376284,4.233333 6.7182939,5.7245206 8.1379048,6.1037675 6.6467171,6.4844329 6.2674703,7.9040438 5.8868048,6.4128561 4.4671939,6.0336093 5.9583816,5.6529438 Z"
|
||||
transform="matrix(0.5045571,0,0,0.5045571,4.360629,1.715138)" /></g></g><g
|
||||
inkscape:groupmode="layer"
|
||||
id="layer2"
|
||||
inkscape:label="refresh"
|
||||
style="display:none;stroke-width:0.529167;stroke-dasharray:none"><path
|
||||
@@ -749,6 +808,27 @@
|
||||
inkscape:label="Arrow_head 1"
|
||||
sodipodi:nodetypes="ccc" /></g><g
|
||||
inkscape:groupmode="layer"
|
||||
id="g691"
|
||||
inkscape:label="extend_wall_to_slab"
|
||||
style="display:none"><g
|
||||
id="g702"
|
||||
transform="rotate(-90,4.2333333,4.2333333)"><rect
|
||||
style="fill:#00d27b;fill-opacity:1;stroke:#ffffff;stroke-width:0;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:0;stroke-dasharray:none;stroke-opacity:1;paint-order:stroke fill markers"
|
||||
id="rect685"
|
||||
width="1.8520824"
|
||||
height="4.2333331"
|
||||
x="-4.7076078e-08"
|
||||
y="2.1166668" /><path
|
||||
style="display:inline;fill:#000000;fill-opacity:1;stroke:#ffffff;stroke-width:0.529;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:0;stroke-dasharray:none;stroke-opacity:1;paint-order:stroke fill markers"
|
||||
d="m 8.2466686,4.2333332 -5.8654186,1e-7"
|
||||
id="path687"
|
||||
sodipodi:nodetypes="cc" /><path
|
||||
style="display:inline;fill:#000000;fill-opacity:0;stroke:#ffffff;stroke-width:0.440014;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1;paint-order:stroke fill markers"
|
||||
d="M 6.874007,5.6059947 8.2466686,4.2333332 C 7.7891148,3.7757794 7.331561,3.3182257 6.8740072,2.860672"
|
||||
id="path689"
|
||||
inkscape:label="Arrow_head 1"
|
||||
sodipodi:nodetypes="ccc" /></g></g><g
|
||||
inkscape:groupmode="layer"
|
||||
id="g12154"
|
||||
inkscape:label="apply_profile"
|
||||
style="display:none"
|
||||
@@ -1908,11 +1988,11 @@
|
||||
inkscape:label="Arrow_head 1"
|
||||
sodipodi:nodetypes="ccc" /></g><g
|
||||
id="g59575"
|
||||
style="display:inline"
|
||||
style="display:none"
|
||||
inkscape:label="2-point_arc"><path
|
||||
id="path60158"
|
||||
style="color:#000000;fill:#00d27b;stroke-linecap:round;-inkscape-stroke:none;paint-order:stroke fill markers;fill-opacity:1"
|
||||
d="M 2.6458333 1.155485 L 2.6458333 2.2344889 C 4.4302591 2.6368603 5.8298528 4.0363549 6.2321777 5.8208333 L 7.3116983 5.8208333 C 6.8759192 3.4585916 5.0080704 1.5912787 2.6458333 1.155485 z " /><path
|
||||
style="color:#000000;fill:#00d27b;fill-opacity:1;stroke-linecap:round;-inkscape-stroke:none;paint-order:stroke fill markers"
|
||||
d="m 2.6458333,1.155485 v 1.0790039 c 1.7844258,0.4023714 3.1840195,1.801866 3.5863444,3.5863444 H 7.3116983 C 6.8759192,3.4585916 5.0080704,1.5912787 2.6458333,1.155485 Z" /><path
|
||||
id="path59567"
|
||||
style="display:none;fill:none;fill-opacity:1;stroke:#00d27b;stroke-width:1.05833;stroke-linecap:square;stroke-linejoin:round;stroke-dasharray:none;stroke-opacity:1;paint-order:stroke fill markers"
|
||||
d="M 6.7842044,5.8631601 C 6.6183054,4.8630407 6.1356283,3.9339006 5.3997928,3.1982064 4.650353,2.4495532 3.6747938,1.9375921 2.6061648,1.732146"
|
||||
|
||||
|
Before Width: | Height: | Size: 153 KiB After Width: | Height: | Size: 158 KiB |
Reference in New Issue
Block a user