<?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[How to connect to MouseArea clicked() signal from C++]]></title><description><![CDATA[<p dir="auto">I can connect to the clicked signal of the QML Button type like this:</p>
<pre><code>QObject::connect(button, SIGNAL(clicked()), this, SLOT(on_clicked()));
</code></pre>
<p dir="auto">How do I connect to the clicked(mouse) signal of the QML MouseArea type?</p>
]]></description><link>https://forum.qt.io/topic/116965/how-to-connect-to-mousearea-clicked-signal-from-c</link><generator>RSS for Node</generator><lastBuildDate>Mon, 10 Aug 2026 19:25:35 GMT</lastBuildDate><atom:link href="https://forum.qt.io/topic/116965.rss" rel="self" type="application/rss+xml"/><pubDate>Mon, 13 Jul 2020 13:39:46 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to How to connect to MouseArea clicked() signal from C++ on Wed, 15 Jul 2020 14:20:02 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/hjpvvv">@<bdi>HJPVVV</bdi></a> hi<br />
<a href="https://doc.qt.io/qt-5/qtqml-cppintegration-interactqmlfromcpp.html#connecting-to-qml-signals" target="_blank" rel="noopener noreferrer nofollow ugc">https://doc.qt.io/qt-5/qtqml-cppintegration-interactqmlfromcpp.html#connecting-to-qml-signals</a></p>
<p dir="auto">also see <a href="https://doc.qt.io/qt-5/qtqml-cppintegration-overview.html" target="_blank" rel="noopener noreferrer nofollow ugc">Overview - QML and C++ Integration</a></p>
<p dir="auto">be aware of this <a href="https://doc.qt.io/qt-5/qtqml-cppintegration-overview.html#interacting-with-qml-objects-from-c" target="_blank" rel="noopener noreferrer nofollow ugc">warning</a></p>
]]></description><link>https://forum.qt.io/post/607003</link><guid isPermaLink="true">https://forum.qt.io/post/607003</guid><dc:creator><![CDATA[ODБOï]]></dc:creator><pubDate>Wed, 15 Jul 2020 14:20:02 GMT</pubDate></item><item><title><![CDATA[Reply to How to connect to MouseArea clicked() signal from C++ on Wed, 15 Jul 2020 14:13:15 GMT]]></title><description><![CDATA[<p dir="auto">Sorry that I did not repeat the entire title in the question.<br />
Hereby I do that: How do I connect to the clicked(mouse) signal of the QML MouseArea type in C++?</p>
]]></description><link>https://forum.qt.io/post/606999</link><guid isPermaLink="true">https://forum.qt.io/post/606999</guid><dc:creator><![CDATA[HJPVVV]]></dc:creator><pubDate>Wed, 15 Jul 2020 14:13:15 GMT</pubDate></item><item><title><![CDATA[Reply to How to connect to MouseArea clicked() signal from C++ on Mon, 13 Jul 2020 13:43:58 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/hjpvvv">@<bdi>HJPVVV</bdi></a></p>
<pre><code>MouseArea {
   anchors.fill:parent
   onClicked:{
     console.log("Mouse Clicked: Do stuff here")
  }
}
</code></pre>
]]></description><link>https://forum.qt.io/post/606507</link><guid isPermaLink="true">https://forum.qt.io/post/606507</guid><dc:creator><![CDATA[J.Hilk]]></dc:creator><pubDate>Mon, 13 Jul 2020 13:43:58 GMT</pubDate></item></channel></rss>