<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Qt Scene. How to draw new items at center of scene?]]></title><description><![CDATA[<p dir="auto">Hi i have function that remove all items from scene but when i'm trying to add new item to scene (after removing all items by using my function) every new item draws slightly to the right of the center. So can you suggest any advice how to draw new items right at center of scene?</p>
]]></description><link>https://forum.qt.io/topic/91348/qt-scene-how-to-draw-new-items-at-center-of-scene</link><generator>RSS for Node</generator><lastBuildDate>Fri, 14 Aug 2026 09:50:24 GMT</lastBuildDate><atom:link href="https://forum.qt.io/topic/91348.rss" rel="self" type="application/rss+xml"/><pubDate>Mon, 04 Jun 2018 22:16:55 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Qt Scene. How to draw new items at center of scene? on Tue, 05 Jun 2018 05:05:08 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/jsulm">@<bdi>jsulm</bdi></a>  im drawing with</p>
<p dir="auto">void listWindow::newNode(int x)<br />
{<br />
scene-&gt;addRect(x, 0, 90, 30, QPen(Qt::black), QBrush(Qt::white));<br />
scene-&gt;addRect(x, 30, 90, 30, QPen(Qt::black), QBrush(QColor(220,220,220)));<br />
scene-&gt;addRect(x, 60, 90, 30, QPen(Qt::black), QBrush(QColor(18,215,255)));<br />
}</p>
<p dir="auto">and deleting with scene-&gt;clear() i think</p>
]]></description><link>https://forum.qt.io/post/461888</link><guid isPermaLink="true">https://forum.qt.io/post/461888</guid><dc:creator><![CDATA[almostz]]></dc:creator><pubDate>Tue, 05 Jun 2018 05:05:08 GMT</pubDate></item><item><title><![CDATA[Reply to Qt Scene. How to draw new items at center of scene? on Tue, 05 Jun 2018 04:53:49 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/almostz">@<bdi>almostz</bdi></a> You should at least show how you're drawing after deleting...</p>
]]></description><link>https://forum.qt.io/post/461886</link><guid isPermaLink="true">https://forum.qt.io/post/461886</guid><dc:creator><![CDATA[jsulm]]></dc:creator><pubDate>Tue, 05 Jun 2018 04:53:49 GMT</pubDate></item></channel></rss>