feat(spothub): column-visibility menu + shrinkable width (#4157)#4280
feat(spothub): column-visibility menu + shrinkable width (#4157)#4280M7HNF-Ian wants to merge 1 commit into
Conversation
…sdr#4157) Right-click the Spot List header to hide/show Comment, Spotter, Band, Mode, Source (Time/Freq/DX Call stay always-on); state persists via AppSettings. Also lowers the dialog's hard-coded 680px minimum width to 360px so it can be dragged narrower once columns are hidden. Band-filter checkboxes now use a wrapping flow layout instead of an equal-stretch QHBoxLayout, so the checked state stays legible instead of compressing to illegibility at narrow widths.
|
Holding for next week's release |
There was a problem hiding this comment.
Nice, self-contained feature — thanks for this, @M7HNF-Ian. The column-visibility menu, the persist/restore loop, and the wrapping band-filter layout all read cleanly and match the surrounding SpotHub style. I checked the parts most likely to bite: BandFilterProxy only overrides filterAcceptsRow, so columns map 1:1 and driving setColumnHidden() with source-column enums is correct; setChecked() is called before the QAction::toggled connect, so restoring the menu state doesn't spurious-save; and the FlowLayout is the canonical Qt example with proper item ownership in the dtor (no leak). The 360px width floor is also safe in practice — the Display tab's fixed-width (90px) toggles already enforce a wider layout minimum, so those tabs can't actually shrink past their content.
One convention item to reconcile, otherwise this looks good to merge.
Would like reconciled before merge (or explicitly waived)
- Principle V: the 5 new column-visibility settings are flat keys (
SpotListColVisible_*); new features are supposed to persist as one nested-JSON object under a single root key. See inline — noting the whole dialog is already flat, so this may be a deliberate consistency call on your/the maintainer's part.
Non-blocking notes
- Worth a quick manual check that the Display/Settings tabs still look right when dragged toward the new 360px floor (I believe they're protected by their own layout minimums, but eyes-on is cheap).
🤖 aethersdr-agent · cost: $3.4240 · model: claude-opus-4-8
| { SpotTableModel::ColComment, "SpotListColVisible_Comment" }, | ||
| { SpotTableModel::ColSpotter, "SpotListColVisible_Spotter" }, | ||
| { SpotTableModel::ColBand, "SpotListColVisible_Band" }, | ||
| { SpotTableModel::ColMode, "SpotListColVisible_Mode" }, | ||
| { SpotTableModel::ColSource, "SpotListColVisible_Source" }, |
There was a problem hiding this comment.
Per Principle V (see the PR template checklist and .specify/memory/constitution.md), new features should persist as a single nested-JSON value under one root key rather than adding flat keys — here that's 5 new top-level keys (SpotListColVisible_Comment, _Spotter, …). Something like a single SpotListColumnVisibility key holding {"Comment": true, "Spotter": false, …} would keep the settings surface tidy and match the convention for new persistence.
That said, the entire DxClusterDialog (and the adjacent band-filter code you touched) already uses flat keys, so a lone nested key here would be locally inconsistent. Reasonable to either follow Principle V for the new feature or deliberately match the surrounding flat style — flagging so it's a conscious choice rather than an oversight.
|
First-pass triage review (not exhaustive — surfacing blockers to keep this moving): Blockers None spotted in a first pass. Verified the load-bearing details:
Secondary notes
Nice, self-contained change — looks good to me on a first pass. |
Closes #4157.
What
hides/shows Comment, Spotter, Band, Mode, Source. Time, Freq, and
DX Call stay always-on. Hidden state persists in AppSettings and
restores on next SpotHub open.
setMinimumSizewidth floor lowered from 680 to 360, sothe window can be dragged narrower once columns are hidden. The
other tabs keep their own natural minimums via Qt's layout
constraints — this only removes the hard-coded override.
to a wrapping flow layout, so the checked/unchecked state stays
legible at narrow widths instead of compressing illegibly.
Test plan
reflows correctly, last visible column absorbs the freed width