Selected-Step Info Panel
The panel that shows the selected machining step's properties. It sits in the Execution Page's Step Info column, where the app labels it Step Properties.
The model is MachiningStep, UserService, the machine coordinates of the current chain and the step variables and color trees the session has registered.
The MachiningStep is assigned by ClStrip.PosSelected.
Show step information for the keys of UserConfig.DisplayedStepPresentKeyList that are on offer — the MachiningStep properties, the machine coordinates of the current chain (MC.X … MC.C, one key per axis of the machine, offered under Coordinate / Move) and the step variables and color trees the session has registered — the project's own, registered from the load on, and others such as a script's RegisterStepVariable and RegisterStepColorTree — offered under Custom. A displayed key that is not on offer is skipped: a step variable the session has not registered yet stays on the list, while the old name of a renamed property drops off at the Step Present dialog's next save. The machine coordinate of a wrap-around rotary axis is printed folded into 0–360°, as the controller's position screen shows it, at the decimals its format prints (SelectedStepInfoService.FormatValue through Common/RotaryReadout.cs, the one fold Block Info and the Color Index Time Chart share); the step itself keeps the continuous angle the engine moves by.
Field names come localized from the server: a MachiningStep property's name and short name are taken from StepPresentCatalog/catalog.{lang}.json for the request language — ?lang= first, which the panel sends, then Accept-Language, then the saved preference — and a catalog entry without a short name gives its translated name for both. In English, for a key the catalog lacks, and when the file is missing or unreadable, they are the attribute's own PresentAttribute.Name and ShortName; see The Server Half. A step variable shows the name it was registered with, and a color tree its name — its key when it has none — untranslated.
Which properties are listed is chosen on the Step Present Preference Page, opened from the Step Present button on this panel's title bar.
Layout
A plain key / value list, not a q-list: the value cell has to shrink and wrap, because a step carries arbitrarily long values (a file path, a whole NC line) and a non-shrinking cell would widen the entire column.
Each row is labelled shortName, falling back to name and then to the raw key, with the full name as the row's tool-tip; the unit follows the value, and an absent value renders as -. A color tree's row prints the leaf the step fell into, its id and its name joined by a middle dot between spaces — 3 · Cut — the id alone for a leaf without a name, and - for a step in no leaf or a read that threw, with no unit: SelectedStepInfoService.FormatValue takes the id and the name from one compiled tree (LocalProjectService.TryGetStepColorTree, then ReadStepColorTreeTrace), read on the request thread. The step file keeps the id alone. With nothing selected the panel shows No step selected. Click a step in the canvas to inspect its info.
The StepIndex row is filtered out even when the configured list contains it — the column's group bar already carries the step index as a badge.
Behavior
Selection bursts (a SetSelectedPos per step while a mission runs) are coalesced into one trailing fetch on an 80 ms timer, and responses are sequence-guarded so a slower earlier fetch cannot overwrite a newer one. A language change re-pulls, because the field names arrive already localized, and so does each save of the Step Present Dialog that lands, so a key just added shows without moving the selection.
Sample Code
Refer to this code to show step information.
internal static void ShowStepPresent(
UserService userEnv, MachiningStep machiningStep)
{
foreach (var entry in userEnv.DisplayedStepPresentAccessList)
{
var present = entry.Value.Present;
var valueText = string.Format("{0:" + present.DataFormatString + "}", entry.Value.GetValueFunc.Invoke(machiningStep));
Console.WriteLine($"{present.ShortName}: {valueText} {present.TailUnitString} ({present.Name} [{entry.Key}])");
}
}
Selection Push (Web Service Only)
SelectedStepInfoService answers the payload on demand: the REST endpoint GET /api/Execution/selected-step-info calls it. It has no SignalR hub of its own — the “selection changed” push rides /clStripHub, whose StepSelected broadcast follows the same PosSelected event. The panel and the cycle-line charts watch that broadcast and re-pull this payload.
Source Code Path
See HiNC App Anatomy for git repository links.
Web Application
HiNC-2025-webservice (Quasar CLI SPA):
wwwroot-src/src/components/execution/SelectedStepInfoPanel.vue— the panel.wwwroot-src/src/components/execution/StepInfoGroupBar.vue— the group bar above it, shared by the step-based panels of the column.Execution/ExecutionController.cs—GET /api/Execution/selected-step-info.Execution/SelectedStepInfoService.cs— the payload, andFormatValue, each row's value as printed, a color tree's leaf and the folded rotary readout among them.Environments/PresentCatalogService.cs— the request language and the catalog the field names are read from.Common/StepInfoPresentKeys.cs— the displayed keys that are on offer, the chain's machine coordinates and the session's step variables and color trees included.Common/RotaryReadout.cs— the fold of a wrap-around rotary axis' machine coordinate into 0–360°, shared with Block Info and the Color Index Time Chart.Execution/ClStripBroadcastService.cs— theStepSelectedbroadcast that tells the panel to re-pull.
HiAPI Engine
HiMech/MachiningSteps/PresentAttribute.cs— theName,ShortNameand unit a row is labelled and suffixed with.HiNc/MachiningProcs/LocalProjectService.ProjectStepColorTrees.cs— the color trees registered as step properties under the tree's name, andTryGetStepColorTreeandReadStepColorTreeTrace, the compiled tree and the leaf a step falls into, which a tree's row prints.HiNc/MachiningProcs/CompiledStepColorTree.cs— the compiled tree's leaves, with their ids and names.
See Also
- Execution Page — the page whose Step Info column hosts this panel
- Step Present Preference Page — chooses which properties are listed
- Step Colors Branch — the color trees, whose key a row prints as the leaf the step fell into
- Inspecting a Step — the task this panel serves, and the rest of the column around it