<?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[[SOLVED] QAction don&#x27;t show the icons]]></title><description><![CDATA[<p dir="auto">I have  the problem, and previously i have tried to find a solution but can't solve the problem.</p>
<p dir="auto">I found in the web, than the problem is the xubuntu used on my pc.<br />
Then recomend me configure the gnome with:<br />
gconftool-2 --type Boolean --set /desktop/gnome/interface/menus_have_icons True<br />
but all are equall.<br />
I have a doubt with where establish the files  ".png" if it should be on "sources" or "Other Files".<br />
I did put on "Other Files", but.... Is this correct?<br />
it seems to had read that I should put it under source, if this is right, could you explain me, how do i  put<br />
the files ".png" under "source"?</p>
<p dir="auto">the program is:</p>
<p dir="auto">@#ifndef ANOTHERMENU_H<br />
#define ANOTHERMENU_H</p>
<p dir="auto">#include &lt;QMainWindow&gt;<br />
#include &lt;QApplication&gt;</p>
<p dir="auto">class AnotherMenu : public QMainWindow<br />
{<br />
public:<br />
AnotherMenu(QWidget *parent = 0);<br />
};</p>
<p dir="auto">#endif // ANOTHERMENU_H<br />
@<br />
@#include "anothermenu.h"<br />
#include &lt;QMenu&gt;<br />
#include &lt;QMenuBar&gt;</p>
<p dir="auto">AnotherMenu::AnotherMenu(QWidget *parent)<br />
: QMainWindow(parent)<br />
{<br />
QPixmap newpix("new.png");<br />
QPixmap openpix("open.png");<br />
QPixmap quitpix("quit.png");</p>
<pre><code>QAction *newa = new QAction(newpix, "&amp;New", this);
QAction *open = new QAction(openpix, "&amp;Open", this);
QAction *quit = new QAction(quitpix, "&amp;Quit", this);
quit-&gt;setShortcut(tr("CTRL+Q"));

QMenu *file;
file = menuBar()-&gt;addMenu("&amp;File");
file-&gt;addAction(newa);
file-&gt;addAction(open);
file-&gt;addSeparator();
file-&gt;addAction(quit);

connect(quit, SIGNAL(triggered()), qApp, SLOT(quit()) );
</code></pre>
<p dir="auto">}</p>
<p dir="auto">@</p>
<p dir="auto">@#include "anothermenu.h"</p>
<p dir="auto">int main(int argc, char *argv[])<br />
{<br />
QApplication a(argc, argv);</p>
<pre><code>AnotherMenu window;

window.resize(550, 400);
window.move(300, 300);
window.setWindowTitle("Another Menu");
window.show();


return a.exec(&amp;#41;;
</code></pre>
<p dir="auto">}@</p>
<p dir="auto">All function Ok, less appear the icons.<br />
Thanks  in advance</p>
]]></description><link>https://forum.qt.io/topic/31413/solved-qaction-don-t-show-the-icons</link><generator>RSS for Node</generator><lastBuildDate>Tue, 22 Sep 2026 15:52:43 GMT</lastBuildDate><atom:link href="https://forum.qt.io/topic/31413.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 30 Aug 2013 20:42:24 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to [SOLVED] QAction don&#x27;t show the icons on Fri, 30 Aug 2013 22:26:27 GMT]]></title><description><![CDATA[<p dir="auto">When i start a project and in my case  named : menus_toolbars2; Creator create two carpets:<br />
-menus_toolbars2<br />
-build-menus_toolbars2-Desktop_5_1_0_GCC_64bit-Debug</p>
<p dir="auto">When i pasted the 3 files ".png" in the carpet menus_toolbars, i did this initially; and compile/run the program, do not appear the icons in menus.</p>
<p dir="auto">But When i pasted the 3 files ".png" in the second carpet, and compile/run the program, NOW already appear the icons in menus</p>
<p dir="auto">Thanks Sgaist for help me</p>
]]></description><link>https://forum.qt.io/post/193500</link><guid isPermaLink="true">https://forum.qt.io/post/193500</guid><dc:creator><![CDATA[[[global:former-user]]]]></dc:creator><pubDate>Fri, 30 Aug 2013 22:26:27 GMT</pubDate></item><item><title><![CDATA[Reply to [SOLVED] QAction don&#x27;t show the icons on Fri, 30 Aug 2013 20:52:42 GMT]]></title><description><![CDATA[<p dir="auto">Hi,</p>
<p dir="auto">Are you sure your images are found ? Giving only the name of the file implies that they reside in the same folder as the application</p>
]]></description><link>https://forum.qt.io/post/193492</link><guid isPermaLink="true">https://forum.qt.io/post/193492</guid><dc:creator><![CDATA[SGaist]]></dc:creator><pubDate>Fri, 30 Aug 2013 20:52:42 GMT</pubDate></item></channel></rss>