feat(ribbon): add layer isolation tools

Closes #589
This commit is contained in:
Hakan Seven committed 2026-07-30 18:07:06 +03:00
1 parent c9aab122f0
commit 02d15f5d23
7 files changed
+81 -7

No files matched your search

+12
View File
@@ -0,0 +1,12 @@
use crate::modules::{IconKind, ModuleEvent, ToolDef};
pub fn tool() -> ToolDef {
ToolDef {
id: "LAYISO",
label: "Isolate Layer",
icon: IconKind::Svg(include_bytes!(
"../../../../assets/icons/layers/layiso.svg"
)),
event: ModuleEvent::Command("LAYISO".to_string()),
}
}
+12
View File
@@ -0,0 +1,12 @@
use crate::modules::{IconKind, ModuleEvent, ToolDef};
pub fn tool() -> ToolDef {
ToolDef {
id: "LAYUNISO",
label: "Unisolate Layers",
icon: IconKind::Svg(include_bytes!(
"../../../../assets/icons/layers/layuniso.svg"
)),
event: ModuleEvent::Command("LAYUNISO".to_string()),
}
}
+2
View File
@@ -1,9 +1,11 @@
pub(super) mod color;
pub(super) mod layfrz;
pub(super) mod layiso;
pub(super) mod laylck;
pub(super) mod layoff;
pub(super) mod layon;
pub(super) mod laythw;
pub(super) mod layuniso;
pub(super) mod layulk;
pub(super) mod make_current;
pub mod match_layer;
+4 -1
View File
@@ -34,7 +34,8 @@ impl CadModule for DrawModule {
use draw::{arc, circle, ellipse, hatch, line, polyline, shapes};
use groups::{group, ungroup};
use layers::{
layfrz, laylck, layoff, layon, laythw, layulk, make_current, match_layer, panel,
layfrz, layiso, laylck, layoff, layon, laythw, layulk, layuniso, make_current,
match_layer, panel,
};
use modify::{
array, copy, delete, explode, fillet, mirror, offset, rotate, scale, stretch,
@@ -182,12 +183,14 @@ impl CadModule for DrawModule {
layfrz::tool(),
laylck::tool(),
make_current::tool(),
layiso::tool(),
],
row3: vec![
layon::tool(),
laythw::tool(),
layulk::tool(),
match_layer::tool(),
layuniso::tool(),
],
},
],