How to give an icon to a submenu group?

I've added a submenu in the 'File' menu, and want to give it an icon.
Logically, I used the 'icon' property, but all I get is a stacktrace.
Any idea?

Alain

]]>
<action id="zipXchange.OpenZippedProject"
...
icon="/icons/minilogo.png" <<----


WORKS FINE
... ]]> <<----


DOESN'T WORK
]]>

0
Avatar
Permanently deleted user

Hi Alain,

I had the same (or similar) problem with my FunkySearch plugin...not only did the icon not show, but it caused a Throwable at IDEA startup. Removing the icon=".." from the ]]> seemed to fix it. See...

http://www.intellij.net/forums/thread.jsp?forum=18&thread=138221&message=3549576

I didn't officially report it as it was only a minor inconvenience for me.

Cheers,
Andrew.

0
Avatar
Permanently deleted user

Andrew

>startup. Removing the icon=".." from the seemed to fix it. See... >]]>

>

Well, I do want to adorn the submenu with an icon, so it doesn't fix it
for me :(.
I wonder if this is possible at all.

Alain

0
Avatar
Permanently deleted user

Is it possible at all?

Alain

0
Avatar
Permanently deleted user

Alain Ravet wrote:

Is it possible at all?

>

Is it?

0

I had similar problems, i now found out that it works by specifying the absolute namespace:

<action id="MyAction" icon="/com/mycompany/myplugin/resources/images/icon.png" ...

0

You can assign an icon to an action or a group ( http://screencast.com/t/anox5w9A6dp )
I'd recommend to have two source roots: one for the code and the other for icons, META-INF, xmls, etc Something like this http://screencast.com/t/ugznxBjcP2Au Important: your icons should be placed to a source directory.
Always use full unix-path to your icon starting from the source root. Say, you have resources folder marked as source root, and there is a folder named icons inside, and there is an icon myaction.png inside icons folder. Path to icon in plugin.xml should look like icon="/icons/myaction.png"

Hope this will help

0

请先登录再写评论。