Repository navigation
Fix initial script dialog sizing from its completed layout - #3700
Merged
Merged
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #3700 +/- ##
==========================================
+ Coverage 74.41% 74.45% +0.03%
==========================================
Files 256 256
Lines 38118 38146 +28
Branches 5139 5145 +6
==========================================
+ Hits 28367 28400 +33
+ Misses 9751 9746 -5 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Owner
|
Thanks for the fix! |
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.
Script dialogs without saved geometry can open at a narrow default width even when their labels need more space. In #3583, a short title leaves much of the form behind scrollbars.
inputDialog()fills unspecified dimensions from the dialog's current size before it has adjusted to its contents, and adds the button box after sizing.Create the button box and apply the stylesheet before calculating the default size with
adjustSize(). Restore saved geometry and apply explicit.width/.heightafterwards. This preserves user sizing and the scroll area's existing size limits for large forms.Add integration tests for initial content fitting and for explicit dimensions followed by restoring a user-resized dialog. The test plugin exposes dialog geometry and a resize action to exercise these behaviors in the real application.
Related to #3583.
Validation on Windows 11 build 22631, MSVC 19.44, Qt 6.10.2, Debug:
81c5c21b60a3bc81c242eb0625a827e68470ad55: horizontal scroll maximum is 124 instead of 0. It passes with the fix.commandDialogFitsContents,commandDialogRestoreGeometry,commandDialog, andcommandDialogCloseOnDisconnectpass (6 passed including suite setup/cleanup, 0 failed).git diff --checkpasses.Optional encryption, keychain, audio, native notifications and regular plugins were disabled for this local build. The test plugin was built and loaded. Full upstream CI, Linux/macOS and Qt 6.10.3 (currently used by Windows CI) have not been run. Existing saved small geometry is intentionally retained.