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
@@ -94,9 +94,8 @@ slot, or the geometry switchboard embedded inline.</p>
<h2 id="layout">Layout</h2>
<ul>
<li><strong>Edit Mode</strong> — a selector over three modes. Its internal values are <code>MinMax</code>, <code>MinDimension</code> and
<code>CenterDimension</code>; the web labels them &ldquo;Min / Max&rdquo;, &ldquo;Min + Dimension&rdquo; and &ldquo;Center + Dimension&rdquo;,
the desktop client &ldquo;Min and Max&rdquo;, &ldquo;Min and Dimension&rdquo; and &ldquo;Center and Dimension&rdquo;.</li>
<li><strong>Min</strong>, <strong>Max</strong>, <strong>Dimension</strong>, <strong>Center</strong> — four vector rows, one X / Y / Z input each. The web
<code>CenterDimension</code>, labelled &ldquo;Min / Max&rdquo;, &ldquo;Min + Dimension&rdquo; and &ldquo;Center + Dimension&rdquo;.</li>
<li><strong>Min</strong>, <strong>Max</strong>, <strong>Dimension</strong>, <strong>Center</strong> — four vector rows, one X / Y / Z input each. The editor
captions Dimension &ldquo;Dimension (Max − Min)&rdquo; and Center &quot;Center ((Max + Min) / 2)&quot;; the Min and Max
captions come from the shared label set rather than the geometry one.</li>
</ul>
@@ -107,18 +106,14 @@ in anything but Center + Dimension.</p>
<p>Only <a class="xref" href="../../api/Hi.Geom.Box3d.html#Hi_Geom_Box3d_Min">Min</a> and <a class="xref" href="../../api/Hi.Geom.Box3d.html#Hi_Geom_Box3d_Max">Max</a> are settable on the type;
<a class="xref" href="../../api/Hi.Geom.Box3d.html#Hi_Geom_Box3d_Dim">Dim</a> and <a class="xref" href="../../api/Hi.Geom.Box3d.html#Hi_Geom_Box3d_Center">Center</a> are derived and get-only. That is why the
other two modes are arithmetic over the same two stored corners rather than a different storage
shape — and on the web that arithmetic happens in the browser, which then posts the resulting Min
and Max.</p>
shape — and that arithmetic happens in the browser, which then posts the resulting Min and Max.</p>
<h2 id="behavior">Behavior</h2>
<ul>
<li><strong>A row commits on blur or Enter, not per keystroke.</strong> The vector widget emits only from its blur
handlers, suppresses the emit when the parsed value is unchanged, and reverts an unparseable entry
to its previous value.</li>
<li><strong>The web editor has no read-only variant.</strong> The desktop control additionally carries an
<code>IsInfoMode</code> property that a host sets to turn the whole control into a display: every field goes
read-only and the Edit Mode selector is hidden outright. Two hosts use it, the STL file control and
the geometry combination control. The web equivalent is not this editor — the STL file editor draws
its own read-only bounding-box rows.</li>
<li><strong>This editor has no read-only variant.</strong> A host that needs one draws its own rows instead — the
STL file editor's read-only bounding-box rows are not this editor.</li>
<li><strong>Four endpoints ship without a caller.</strong> The controller exposes <code>UpdateByMinDimension</code>,
<code>UpdateByCenterDimension</code>, <code>IndexDimension</code> and <code>IndexCenter</code>; the shipped SPA calls none of them,
because the editor resolves every mode to a plain <code>Update</code>.</li>