Loading files
c730ec352This file is pinned to the selected release. Download the original to open it in your design tool.
import { LengthEdit } from "../../widgets.slint";
import {
Board2dTabData,
WindowSectionData,
} from "../../api.slint";
export component AddHoleToolBar inherits HorizontalLayout {
in property <int> section-index;
in-out property <WindowSectionData> section;
property <[Board2dTabData]> tabs: section.board-2d-tabs;
spacing: 2px;
drill-edt := LengthEdit {
data: tabs[section.current-tab-index].tool-drill;
icon: @image-url("../../../../font-awesome/svgs/solid/bore-hole.svg");
tooltip: @tr("Via Drill Diameter");
min-width-text: "1.234";
value-changed(v) => {
tabs[section.current-tab-index].tool-drill.value = v;
}
unit-changed(u) => {
tabs[section.current-tab-index].tool-drill.unit = u;
}
increase-triggered => {
tabs[section.current-tab-index].tool-drill.increase = true;
}
decrease-triggered => {
tabs[section.current-tab-index].tool-drill.decrease = true;
}
}
}