D27669: WIP: [kstyle] Tools area

Hugo Pereira Da Costa noreply at phabricator.kde.org
Sat Feb 29 21:29:28 GMT 2020


hpereiradacosta added inline comments.

INLINE COMMENTS

> breezehelper.cpp:1726
> +
> +        painter->setPen(QPen(outline, 1*widget->screen()->devicePixelRatio()));
> +        painter->setBrush(Qt::NoBrush);

No. Should be QPen( outline, 1) or just "outline"
DevicePixelRatio is handled by paint engine.

> breezestyle.cpp:882
> +
> +                painter->setPen(QPen(outline, 1*widget->screen()->devicePixelRatio()));
> +                painter->setBrush(Qt::NoBrush);

Same remark

> breezetoolsareamanager.cpp:97
> +
> +    void ToolsAreaManager::registerWidget(QWidget *widget)
> +    {

As far as I have followed the code you need an "unregisterWidget" for when widgets are unpolished and to remove windows from the map. 
You also need a connection to the destroyed signal to cleanup the map when a widget is deleted, otherwise you will keep accumulating an ever growing map of dangling pointers.

REPOSITORY
  R31 Breeze

REVISION DETAIL
  https://phabricator.kde.org/D27669

To: cblack, #plasma, #breeze, #vdg
Cc: hpereiradacosta, gvgeo, ngraham, manueljlin, niccolove, ndavis, plasma-devel, Orage, LeGast00n, The-Feren-OS-Dev, cblack, jraleigh, zachus, fbampaloukas, GB_2, ragreen, ZrenBot, himcesjf, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, ahiemstra, mart
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20200229/acc8c1a0/attachment.html>


More information about the Plasma-devel mailing list