This commit is contained in:
2026-09-09 18:06:21 +08:00
parent 161af68fe3
commit 45b9f9ed5d
79 changed files with 1167 additions and 1532 deletions
@@ -103,12 +103,6 @@ leaf)</li>
</ul>
<p>Key Model: <a class="xref" href="../../api/Hi.Machining.MachiningEquipmentUtils.SetupEquipment.html">SetupEquipment</a> (+ its
<a class="xref" href="../../api/Hi.Machining.MachiningEquipmentUtils.SetupEquipment.html#Hi_Machining_MachiningEquipmentUtils_SetupEquipment_CoolantHeatCondition">CoolantHeatCondition</a>).</p>
<div class="NOTE">
<h5>Note</h5>
<p>The WPF desktop app has no surface for either value — no page, no panel, and no handler for the
<code>.CoolantHeatCondition</code> extension. There, both are whatever the project XML carries on the
equipment face, or the class defaults when the XML says nothing.</p>
</div>
<h2 id="layout">Layout</h2>
<ul>
<li>Background leaf — <code>equipment/background</code>, item type <code>ThermalCondition</code>
@@ -252,8 +252,7 @@ decides which axis consumes which position table, is <em>shown</em> on
written here as an <strong>Axis parameters (integer)</strong> row; the REST surface carries no assignment writer
at all. The equidistant definition — the numerator <code>MD30501</code> and the offset <code>MD30503</code> as axis
parameters, the denominator <code>MD30502</code> as an integer axis parameter — has no endpoint that reads or
writes it and no panel that offers a cell for it: on the web surface it is three ordinary rows on
this leaf. The engine is its reader: an axis whose <code>MD30500</code> is 3 resolves its station spacing from
writes it and no panel that offers a cell for it: it is three ordinary rows on this leaf. The engine is its reader: an axis whose <code>MD30500</code> is 3 resolves its station spacing from
the trio, and Indexing Position Tables prints that axis' assignment as <em>Equidistant
(MD30501–MD30503)</em>, naming the three numbers it offers no cell for. The two position lists
themselves are the mirror image, stored as list properties outside all three dictionaries and so
@@ -93,18 +93,16 @@ surfaces:</p>
<ul>
<li>the <code>equipment/fixture</code> branch of the General Setup page's Control Tree
(<code>/general-setup?tree=equipment/fixture</code>), an equipment child of the General Setup group between
Coolant and Workpiece. <code>/fixture</code> and anything below it redirects there;</li>
<li>in the WPF client, a sub-window opened from the <a class="xref" href="../shell/main-panel.html">Main Panel</a>.</li>
Coolant and Workpiece. <code>/fixture</code> and anything below it redirects there.</li>
</ul>
<p>Both edit the one fixture the project owns.</p>
<p>It edits the one fixture the project owns.</p>
<ul>
<li>Key Model:
<ul>
<li><a class="xref" href="../../api/Hi.NcMech.Fixtures.Fixture.html">Fixture</a>
On the web it is addressed by an IndexService key handed to the
It is addressed by an IndexService key handed to the
<a class="xref" href="../widget/object-management-menu-button.html">Object Management Menu Button</a> and installed back onto
the project through the controller's UpdateFixture. On the WPF client the same button is wired
with a TargetObjectGetter / TargetObjectSetter pair (see that page for the design pattern).</li>
the project through the controller's UpdateFixture.</li>
</ul>
</li>
<li>Assistant Model:
@@ -114,14 +112,11 @@ with a TargetObjectGetter / TargetObjectSetter pair (see that page for the desig
</ul>
</li>
</ul>
<p>The displayee differs by client. The web branch has no fixture-only canvas: it shares the General
Setup canvas, whose displayee is the equipment-setup displayee (<code>Disp/EquipmentSetupDisplayee.cs</code>) —
the merged fixture + workpiece scene with the anchor, buckle and controller-coordinate overlays. Its
option set is the equipment-setup config (<code>Disp/EquipmentSetupDisplayeeConfig.cs</code>), carried on
<code>UserService.UserConfig</code> as its <code>EquipmentSetupDisplayeeConfig</code> property. The WPF sub-window has a
canvas of its own, whose displayee is <a class="xref" href="../../api/Hi.NcMech.Fixtures.FixtureEditorDisplayee.html">FixtureEditorDisplayee</a> configured by
<a class="xref" href="../../api/Hi.NcMech.Fixtures.FixtureEditorDisplayeeConfig.html">FixtureEditorDisplayeeConfig</a>, taken from <code>UserService.UserConfig</code> as its
<code>FixtureSetupDisplayeeConfig</code> property.</p>
<p>There is no fixture-only canvas: the branch shares the General Setup canvas, whose displayee is the
equipment-setup displayee (<code>Disp/EquipmentSetupDisplayee.cs</code>) — the merged fixture + workpiece scene
with the anchor, buckle and controller-coordinate overlays. Its option set is the equipment-setup
config (<code>Disp/EquipmentSetupDisplayeeConfig.cs</code>), carried on <code>UserService.UserConfig</code> as its
<code>EquipmentSetupDisplayeeConfig</code> property.</p>
<h2 id="layout">Layout</h2>
<h3 id="control-tree-branch">Control Tree Branch</h3>
<p>The root panel is rendered inline by the dock's primary editor pane, so it has no title label of its
@@ -164,53 +159,10 @@ Display Options dropdown carries this branch's share of the scene — the <stron
Solid / Edge / Hide radio group, and the Fixture Geom Anchor, Workpiece Buckle and Table Buckle
flags in the Anchors group.</li>
</ul>
<h3 id="wpf-page">WPF Page</h3>
<ul>
<li>Head Line
<ul>
<li><a class="xref" href="../widget/object-management-menu-button.html">Object Management Menu Button</a> — file extension
<code>.Fixture</code>, load type <a class="xref" href="../../api/Hi.NcMech.Fixtures.Fixture.html">Fixture</a>, rel file <code>Fixture.xml</code>. The pointed
Editor Panel is the Management Tabs Panel, a ContentPresenter the button swaps between the tab
stack and XML mode.</li>
<li>Title Label</li>
</ul>
</li>
<li>Management Tabs Panel — the same content the tree renders as nodes, stacked as tabs:
<ul>
<li>Geometry Tab — <a class="xref" href="../geom/geom-manage-control.html">Geometry Management Control</a> over
<a class="xref" href="../../api/Hi.NcMech.Fixtures.Fixture.html#Hi_NcMech_Fixtures_Fixture_Geom">Geom</a>.</li>
<li>Anchor Tab — a nested tab stack, each tab a
<a class="xref" href="../geom/transformer-panel.html">Transformer Manage Panel</a>:
<ul>
<li>Geom To Workpiece Tab</li>
<li>Geom To Table Tab</li>
</ul>
</li>
</ul>
</li>
<li>Viewer Panel
<ul>
<li>Viewer ToolBar
<ul>
<li><a class="xref" href="../widget/renderingcanvas-tool-bar.html">RenderingCanvas Tool Bar</a></li>
<li>Display Options menu — the Show Geom Anchor, Show Workpiece Buckle and Show Table Buckle
checkboxes and the Solid / Edge / Hide rendering-mode radio group, all writing
<a class="xref" href="../../api/Hi.NcMech.Fixtures.FixtureEditorDisplayeeConfig.html">FixtureEditorDisplayeeConfig</a>.</li>
</ul>
</li>
<li>RenderingCanvas — its <a class="xref" href="../../api/Hi.Disp.DispEngine.html">DispEngine</a>.<a class="xref" href="../../api/Hi.Disp.DispEngine.html#Hi_Disp_DispEngine_Displayee">Displayee</a> is
<a class="xref" href="../../api/Hi.NcMech.Fixtures.FixtureEditorDisplayee.html">FixtureEditorDisplayee</a>.</li>
</ul>
</li>
</ul>
<p>Both clients put a draggable divider between the editor column and the canvas: a GridSplitter in the
WPF page, nested draggable splitters on the web page (dock / content column / canvas), plus the
dock's own height divider between the tree row and the editor row.</p>
<h2 id="behavior">Behavior</h2>
<ul>
<li><a class="xref" href="../../api/Hi.NcMech.Fixtures.Fixture.html#Hi_NcMech_Fixtures_Fixture_ClearGeomCache">ClearGeomCache()</a> runs after any change at or below the branch. On
the web each node's afterChange chain ends in the controller's ClearGeometryCache, which calls it;
in WPF the page calls it directly from the geometry control's setter and update callbacks.</li>
<li><a class="xref" href="../../api/Hi.NcMech.Fixtures.Fixture.html#Hi_NcMech_Fixtures_Fixture_ClearGeomCache">ClearGeomCache()</a> runs after any change at or below the branch:
each node's afterChange chain ends in the controller's ClearGeometryCache, which calls it.</li>
<li>The two anchor slots re-commit their swap-in <em>before</em> clearing the cache: an inner-value edit
re-posts UpdateGeomToWorkpieceTransformer / UpdateGeomToTableTransformer, so the object the
switchboard produced is always the one installed on the owning field when the redraw happens.</li>
@@ -222,10 +174,7 @@ once.</li>
<li>Kind pickers are parent-aware. Picking a geometry kind calls CreateGeometry, which installs the
new object on <a class="xref" href="../../api/Hi.NcMech.Fixtures.Fixture.html#Hi_NcMech_Fixtures_Fixture_Geom">Geom</a> server-side and maps the literal <code>None</code> to
null; picking a transformer kind creates the object and then rebinds the owning field.</li>
<li>View snapping differs by client. The WPF page snaps its canvas to the isometric view when the
displayee is bound, and again whenever a new geometry object is set, on the assumption that a
shape swap changes the scene more than an edit within one shape does. The shared web canvas snaps
once, when its displayee is bound — the display controller's initialize does it server-side.
<li>The shared canvas snaps to the isometric view once, when its displayee is bound — the display controller's initialize does it server-side.
Afterwards a geometry set only clears the cache, and the operator re-frames from the
<a class="xref" href="../widget/renderingcanvas-tool-bar.html">RenderingCanvas Tool Bar</a>'s view picker.</li>
<li>Both canvases draw the live model, so an edit shows on the next frame with no further calls.</li>
@@ -287,13 +236,11 @@ fixture + workpiece scene with the anchor, buckle and controller-coordinate over
<ul>
<li><code>HiMech/NcMech/Fixtures/Fixture.cs</code> — the key model: the geometry, the table and workpiece
buckles, the geom anchor, the two anchor transformers and ClearGeomCache.</li>
<li><code>HiMech/NcMech/Fixtures/FixtureEditorDisplayee.cs</code> — the WPF fixture canvas's displayee.</li>
<li><code>HiMech/NcMech/Fixtures/FixtureEditorDisplayeeConfig.cs</code> — its option set: ShowGeomAnchor,
ShowWorkpieceBuckle, ShowTableBuckle and the rendering mode.</li>
</ul>
<h2 id="see-also">See Also</h2>
<ul>
<li><a class="xref" href="../util/mech-builder.html">Mechanism Builder Page</a> — reuses this page’s parent-aware transformer rebind pattern</li>
<li><a class="xref" href="../tool-house/holder/freeform-holder-panel.html">Freeform Holder Panel</a> — the other surface built from the same generic Geometry and Transformer slots</li>
</ul>
</article>
@@ -97,18 +97,16 @@ group and a <strong>leaf</strong>: chain structure belongs to the
<li>the <code>/machine-tool</code> route, a standalone surface pairing a chain-only canvas with a load button
and a GUI / XML view of what is loaded. Its fields are read-only, but the route is not: its Load
installs the picked chain file onto the project. It carries no Page-menu entry and is reached by
URL;</li>
<li>in the WPF client, a sub-window opened from the <a class="xref" href="../shell/main-panel.html">Main Panel</a>.</li>
URL.</li>
</ul>
<p>All three edit the one chain the project owns.</p>
<p>Both edit the one chain the project owns.</p>
<ul>
<li>Key Model:
<ul>
<li><a class="xref" href="../../api/Hi.Mech.IMachiningChain.html">IMachiningChain</a>
On the web the chain is addressed by an IndexService key handed to the
The chain is addressed by an IndexService key handed to the
<a class="xref" href="../widget/object-management-menu-button.html">Object Management Menu Button</a> and installed back onto
the project through the controller's Update. On the WPF client the same button is wired with a
TargetObjectGetter / TargetObjectSetter pair (see that page for the design pattern).</li>
the project through the controller's Update.</li>
</ul>
</li>
<li>Assistant Model:
@@ -184,43 +182,6 @@ fetched lazily on the first switch to XML and re-fetched after a load while XML
</ul>
</li>
</ul>
<h3 id="wpf-page">WPF Page</h3>
<ul>
<li>Head Line
<ul>
<li><a class="xref" href="../widget/object-management-menu-button.html">Object Management Menu Button</a>
<ul>
<li>file extension is <code>mt</code>; the load type is <a class="xref" href="../../api/Hi.Mech.IMachiningChain.html">IMachiningChain</a>.</li>
<li>The pointed Editor Panel is Management Panel — a ContentPresenter the button swaps between the
built GUI panel and an AvalonEdit text editor for XML mode.</li>
</ul>
</li>
<li>Title Label &ldquo;Machine Tool&rdquo;</li>
</ul>
</li>
<li>Management Panel
<ul>
<li>If the key model inherits <a class="xref" href="../../api/Hi.Common.INameNote.html">INameNote</a>:
<ul>
<li>Name Setting Line
<ul>
<li>Name Label</li>
<li>Name TextField — its TextChanged writes straight onto the chain.</li>
</ul>
</li>
<li>Note Setting Line
<ul>
<li>Note Label</li>
<li>Note TextField — multi-line, same write-through.</li>
</ul>
</li>
</ul>
</li>
<li>Type Line — italic <code>Type: {chain type}</code>.</li>
<li>Empty-state label when no chain is loaded.</li>
</ul>
</li>
</ul>
<h2 id="behavior">Behavior</h2>
<ul>
<li>Load / Paste / XML-Apply only swap the IndexService entry. The tree root then installs the result
@@ -109,13 +109,6 @@ side-file reference
</ul>
</li>
</ul>
<div class="NOTE">
<h5>Note</h5>
<p>The WPF desktop app has no spindle-capability surface: no page, no panel, and no handler for the
<code>.SpindleCapability</code> extension. There, the value is whatever the project XML carries on the
equipment face, or the class defaults when the XML says nothing. The <code>.SpindleCapability</code> object
management menu ships on the web only, on this branch's root panel.</p>
</div>
<h2 id="layout">Layout</h2>
<p>The branch is one root plus five children, six selectable nodes in all. Each node's editor occupies
the dock's PRIMARY row, and all six — the root included — register the <em>same</em> CONTENT-column view,
@@ -87,16 +87,14 @@
<article data-uid="Anatomy-Workpiece">
<h1 id="workpiece">Workpiece</h1>
<p>The Workpiece editor is the <code>equipment/workpiece</code> branch of the General Setup page's Control Tree (<code>/general-setup?tree=equipment/workpiece</code>); the old <code>/workpiece</code> route redirects there. In the WPF client it is a sub-window opened from the <a class="xref" href="../shell/main-panel.html">Main Panel</a>.</p>
<p>The Workpiece editor is the <code>equipment/workpiece</code> branch of the General Setup page's Control Tree (<code>/general-setup?tree=equipment/workpiece</code>); the old <code>/workpiece</code> route redirects there.</p>
<p>The key model is <a class="xref" href="../../api/Hi.NcMech.Workpieces.Workpiece.html">Workpiece</a>, taken from the Main Panel's
<a class="xref" href="../../api/Hi.MachiningProcs.LocalProjectService.html#Hi_MachiningProcs_LocalProjectService_Workpiece">Workpiece</a>. The cached solids it is drawn from belong to
<a class="xref" href="../../api/Hi.NcMech.Workpieces.WorkpieceService.html">WorkpieceService</a>, which both clients share.</p>
<p>The display config differs by client. The web branch has none of its own: it shares the General Setup
canvas, gated by the equipment-setup config (<code>Disp/EquipmentSetupDisplayeeConfig.cs</code>), which carries
<a class="xref" href="../../api/Hi.NcMech.Workpieces.WorkpieceService.html">WorkpieceService</a>.</p>
<p>The branch has no display config of its own: it shares the General Setup canvas, gated by the equipment-setup config (<code>Disp/EquipmentSetupDisplayeeConfig.cs</code>), which carries
the fixture and workpiece flags together — the fixture and workpiece geometry anchors keep separate
flags, while the fixture↔workpiece buckle pair, being one attached identity at one location, is a
single flag. The WPF page takes its own <a class="xref" href="../../api/Hi.NcMech.Workpieces.WorkpieceEditorDisplayeeConfig.html">WorkpieceEditorDisplayeeConfig</a>
from <code>UserService.UserConfig</code>.</p>
single flag.</p>
<h2 id="layout">Layout</h2>
<h3 id="control-tree-branch">Control Tree Branch</h3>
<ul>
@@ -205,120 +203,6 @@ fixture↔workpiece pair), Table Buckle, <strong>Workpiece Geometry Anchor</stro
</ul>
</li>
</ul>
<h3 id="wpf-page">WPF Page</h3>
<ul>
<li>Workpiece Page
<ul>
<li>Management Panel
<ul>
<li>Head Line
<ul>
<li><a class="xref" href="../widget/object-management-menu-button.html">Object Management Menu Button</a>
<ul>
<li>file extension is <code>.Workpiece</code>; the load type is <a class="xref" href="../../api/Hi.NcMech.Workpieces.Workpiece.html">Workpiece</a></li>
<li>The pointed Editor Panel is Management Tabs Panel</li>
</ul>
</li>
<li>Title Label</li>
</ul>
</li>
<li>Management Tabs Panel
<ul>
<li>Raw Shape Tab
<ul>
<li>Raw Geometry Source DropDown (Common Geometry and Meshed Geometry are EXCLUSIVE)
<ul>
<li>Common Geometry
Apply <a class="xref" href="../geom/geom-manage-control.html">Geometry Management Control</a></li>
<li>Meshed Geometry
Apply <a class="xref" href="../geom/meshed-geom-panel.html">Meshed Geometry Panel</a></li>
</ul>
</li>
</ul>
</li>
<li>Target Shape Tab
<ul>
<li>Geometry Management Control</li>
</ul>
</li>
<li>Anchor Tab
<ul>
<li>Geom To Fixture Tab
<ul>
<li><a class="xref" href="../geom/transformer-panel.html">Transformer Manage Panel</a></li>
</ul>
</li>
<li>Geom To Program-Zero Tab
<ul>
<li>Transformer Manage Panel</li>
</ul>
</li>
</ul>
</li>
<li>Runtime Tab
<ul>
<li>Initial Resolution Dropdown — the same powers-of-two ladder as the Mesh item above.</li>
</ul>
</li>
<li>Material Tab
Visible if <code>UserService.EnablePhysics</code> is true.
<ul>
<li>Workpiece Material File Selector
<ul>
<li>Browse Button
The initial directory is the project directory.</li>
<li>Browse Resource Button
The directory is the Default Resource directory.</li>
<li>Readonly File Path TextBox</li>
<li>Readonly Name TextBox (<a class="xref" href="../../api/Hi.Common.INameNote.html#Hi_Common_INameNote_Name">Name</a>)
<ul>
<li>ToolTip: <a class="xref" href="../../api/Hi.Common.INameNote.html#Hi_Common_INameNote_Note">Note</a></li>
</ul>
</li>
</ul>
</li>
<li>Cutting Parameter File Selector
<ul>
<li>Browse Button
The initial directory is the project directory.</li>
<li>Browse Resource Button
The directory is the Default Resource directory.</li>
<li>Readonly File Path TextBox</li>
<li>Readonly Name TextBox (<a class="xref" href="../../api/Hi.Common.INameNote.html#Hi_Common_INameNote_Name">Name</a>)
<ul>
<li>ToolTip: <a class="xref" href="../../api/Hi.Common.INameNote.html#Hi_Common_INameNote_Note">Note</a></li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
<li>Viewer Panel
<ul>
<li>Viewer ToolBar
<ul>
<li><a class="xref" href="../widget/renderingcanvas-tool-bar.html">RenderingCanvas Tool Bar</a></li>
<li>SetupDisplayee Options ToolBar
<ul>
<li>Options of <a class="xref" href="../../api/Hi.NcMech.Workpieces.WorkpieceEditorDisplayee.html">WorkpieceEditorDisplayee</a></li>
</ul>
</li>
</ul>
</li>
<li>RenderingCanvas
<ul>
<li>The <a class="xref" href="../../api/Hi.Disp.DispEngine.html">DispEngine</a>.<a class="xref" href="../../api/Hi.Disp.DispEngine.html#Hi_Disp_DispEngine_Displayee">Displayee</a> is <a class="xref" href="../../api/Hi.NcMech.Workpieces.WorkpieceEditorDisplayee.html">WorkpieceEditorDisplayee</a> (Apply the model <a class="xref" href="../../api/Hi.NcMech.Workpieces.WorkpieceEditorDisplayeeConfig.html">WorkpieceEditorDisplayeeConfig</a>).</li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
</ul>
<h2 id="default-resource">Default Resource</h2>
<p>The default resources of Workpiece Material and Cutting Parameter exist in <code>Resource</code> folder under application folder (Not project folder). Both clients seed their file pickers at the matching <code>Resource</code> sub folder:</p>
<ul>
@@ -336,9 +220,7 @@ None leaves the old object indexed, and re-committing would resurrect it.</p>
</li>
<li><p>Call <a class="xref" href="../../api/Hi.NcMech.Workpieces.WorkpieceService.html">WorkpieceService</a>.<a class="xref" href="../../api/Hi.NcMech.Workpieces.WorkpieceService.html#Hi_NcMech_Workpieces_WorkpieceService_ClearIdealGeomCache">ClearIdealGeomCache()</a> on Target Shape set or changed.</p>
</li>
<li><p>Both clients reach that one service by different routes: the web branch posts the controller's
cache-clear endpoints, and the WPF page calls
<a class="xref" href="../../api/Hi.NcMech.Workpieces.WorkpieceEditorDisplayee.html">WorkpieceEditorDisplayee</a>, which forwards to the same service.</p>
<li><p>The branch reaches that service by posting the controller's cache-clear endpoints.</p>
</li>
<li><p>Anchor edits re-commit their transformer and deliberately do <strong>not</strong> clear the geometry cache, so
a placement change forces no <code>CubeTreeFile</code> re-mesh.</p>
@@ -348,10 +230,7 @@ cache chain runs after a change.</p>
</li>
<li><p>The equipment canvas snaps to the isometric view when its displayee is bound to a rendering
connection; a shape edit on the branch re-commits and clears the cache so the next frame
re-solidifies, and leaves the view alone. The WPF page snaps its own canvas to isometric when a
Raw or Target shape is <em>set</em> to a different object, and whenever its meshed-geometry panel updates
its content — the assumption being that setting a shape changes the viewer more than changing its
content does, so only the setter event adjusts the view.</p>
re-solidifies, and leaves the view alone.</p>
</li>
<li><p>Keep <a href="../conventions/gui-file-path-assignment.html#portability">Portability</a> of the Material properties.</p>
</li>