<table><tr><td style="">elvisangelaccio created this revision.<br />elvisangelaccio added a reviewer: davidedmundson.<br />Restricted Application added a project: Frameworks.<br />Restricted Application added a subscriber: kde-frameworks-devel.<br />elvisangelaccio requested review of this revision.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D13570">View Revision</a></tr></table><br /><div><strong>REVISION SUMMARY</strong><div><p>It's not clear why, but the combination of a word-wrapped QLabel with<br />
the <tt style="background: #ebebeb; font-size: 13px;">setFocusPolicy()</tt> call in <tt style="background: #ebebeb; font-size: 13px;">overrideFocusPolicyOf()</tt> seems to break<br />
the positioning of the groupbox in its parent layout.</p>

<p>Until we understand where the bug is and how to fix it, we can toggle<br />
the groupbox twice when we detect that a QLabel with word-wrapping<br />
enabled has been added as child. Not clear why (again), but this fixes<br />
(or at least hides) the issue.</p></div></div><br /><div><strong>TEST PLAN</strong><div><p>Apply the patch, then run <tt style="background: #ebebeb; font-size: 13px;">kcollapsiblegroupboxtest</tt> with/without the workaround compiled in.</p></div></div><br /><div><strong>REPOSITORY</strong><div><div>R236 KWidgetsAddons</div></div></div><br /><div><strong>BRANCH</strong><div><div>workaround-wordwrap (branched from master)</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D13570">https://phabricator.kde.org/D13570</a></div></div><br /><div><strong>AFFECTED FILES</strong><div><div>src/kcollapsiblegroupbox.cpp<br />
tests/kcollapsiblegroupboxtest.cpp</div></div></div><br /><div><strong>To: </strong>elvisangelaccio, davidedmundson<br /><strong>Cc: </strong>kde-frameworks-devel, michaelh, ngraham, bruns<br /></div>