fix(gui): pack XVTR setup fields with trailing stretch (#3454)#3456
Merged
Conversation
The XVTR tab in the Radio Setup dialog showed large, uneven vertical gaps between every field row (Name, RF/IF Freq, LO Freq/Error, RX Gain/RX Only, Max Power) compared to sibling tabs. Root cause: buildXvtrTab() was the only Radio Setup tab whose outer QVBoxLayout did not end with addStretch(1). Every other tab (TX, RX, Audio, Filters, APD, ...) terminates its vbox with a trailing stretch. Without it, the layout handed all leftover vertical space to the QTabWidget, and the inner QGridLayout — which has 5 content rows and no row-stretch factors — distributed that slack evenly between the rows, producing the excessive gaps. Add vbox->addStretch(1) after the tab widget so the QTabWidget collapses to its compact size hint and the field rows pack tightly at the top, matching the spacing of the other tabs. Fixes aethersdr#3454 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Co-authored-by: Codex <noreply@openai.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The XVTR tab in the Radio Setup dialog renders with large, uneven vertical gaps between every field row (Name, RF Freq/IF Freq, LO Freq/LO Error, RX Gain/RX Only, Max Power), unlike the tightly-packed sibling tabs (GPS, Audio, TX, RX, Antennas, Filters, APD, USB Cables, Peripherals).
Fixes #3454.
Root cause
RadioSetupDialog::buildXvtrTab()was the only Radio Setup tab whose outerQVBoxLayoutdid not terminate withaddStretch(1). Every sibling builder does:vbox->addStretch(1)buildTxTab)buildRxTab)buildAudioTab)buildFiltersTab)buildApdTab)buildXvtrTab)Without that trailing stretch, the
QVBoxLayouthad no flexible element to absorb leftover vertical space, so it handed all of it to theQTabWidget. The tab widget grew to fill the dialog, and the inner per-transverterQGridLayout— which has 5 content rows and no row-stretch factors — distributed the surplus height evenly across the rows. That even distribution is exactly the excessive inter-row spacing reported in the issue.Fix
Add a single trailing stretch after the tab widget:
The stretch now absorbs the leftover vertical space, so the
QTabWidgetcollapses to its compact size hint and the inner grid receives only its natural height — packing the field rows tightly at the top and matching the layout density of the other tabs. Behaviour on dialog resize (content stays top-aligned, empty space below) is now identical to the sibling tabs.One-line, layout-only change; no behavioural or data-path impact.
Testing
cmake --build build -j22, RelWithDebInfo, macOS) — clean,[1042/1042].💻 Generated with Claude Code (Opus 4.8) with architecture by @jensenpat