<table><tr><td style="">romangg created this revision.<br />romangg added reviewers: KWin, zzag, davidedmundson.<br />Herald added a project: Plasma.<br />Herald added a subscriber: plasma-devel.<br />romangg 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/D15907">View Revision</a></tr></table><br /><div><strong>REVISION SUMMARY</strong><div><p>In <a href="https://phabricator.kde.org/R129:c9cfd840137b65bc7391f301f4f63da6df9de859" style="background-color: #e7e7e7;
          border-color: #e7e7e7;
          border-radius: 3px;
          padding: 0 4px;
          font-weight: bold;
          color: black;text-decoration: none;">c9cfd840137b</a> a position contains check was introduced in order to not count<br />
a bottom or right edge position as being part of the DecorationButton like<br />
QRectF::contains does.</p>

<p>This was done by converting the geometry to a QRect and using its contains<br />
function, which does the comparision the desirable way for legacy reasons.</p>

<p>But this means we lose precision, since the decoration library in theory<br />
supports floating values for positioning.</p>

<p>To not do this instead of using QRect's functionality and implicitly dropping<br />
float precision therefore do the check for bottom and right edge explicitly.</p></div></div><br /><div><strong>TEST PLAN</strong><div><p>Adapted autotest.</p></div></div><br /><div><strong>REPOSITORY</strong><div><div>R129 Window Decoration Library</div></div></div><br /><div><strong>BRANCH</strong><div><div>decorationContainsFix</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D15907">https://phabricator.kde.org/D15907</a></div></div><br /><div><strong>AFFECTED FILES</strong><div><div>autotests/decorationbuttontest.cpp<br />
src/decorationbutton.cpp</div></div></div><br /><div><strong>To: </strong>romangg, KWin, zzag, davidedmundson<br /><strong>Cc: </strong>plasma-devel, ragreen, Pitel, ZrenBot, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, mart<br /></div>