Community
Participate
Working Groups
Build ID: I20070503-1400 Steps To Reproduce: 1. create a new plugin project using the sample rcp mail template application using eclipse 3.3 on a windows 2000 pc 2. add a org.eclipse.ui.commands 3. add extension point org.eclipse.ui.menus and add that command as menuContribution to the main toolbar (toolbar:org.eclipse.ui.main.toolbar?after=additions) 4. icon will be displayed but it does not have that "flat" look like the two existing buttons - regardless of which style attribute will be used at the menucontribution More information: Since we upgraded from 3.2.1 to 3.3M6 and further to 3.3M7 we have introduced org.eclipse.ui.commands, org.eclipse.ui.menus and org.eclipse.ui.handlers to replace all o.e.ui.ActionSets, o.e.ui.popUpMenus etc. Everything works well except the commands added to the with toolbar:org.eclipse.ui.main.toolbar using menuContributions do not have that flat look like as if they would been added to coolbar in the old programmatical way. Regardless which style attribute is set, the added commands always have a 3D-like style. To reproduce that problem we have extended the eclipse rcp mail template application by a org.eclipse.ui.command and a org.eclipse.ui.menus/menuContribution that adds that command to the org.eclipse.ui.main.toolbar. Snipplet of the plugin.xml <!-- start extension --> <extension point="org.eclipse.ui.commands"> <command defaultHandler="com.mobilkom.rcp.sample.mail.OpenMailboxHandler" id="com.mobilkom.rcp.sample.mail.openMailboxCommand" name="Open Mailbox"> </command> </extension> <extension point="org.eclipse.ui.menus"> <menuContribution locationURI="toolbar:org.eclipse.ui.main.toolbar?after=additions"> <toolbar id="mainToolbar"> <command commandId="com.mobilkom.rcp.sample.mail.openMailboxCommand" icon="icons/sample3.gif" label="Mailboxes (Command)"> </command> </toolbar> </menuContribution> </extension> <!-- end extension --> Regardless of the used style attribute (even if its empty) the added command always has a 3D-like look. This problems exists on Windows 2000, which is our primary platform but does not occur on Windows XP. We already made inital test on Windows Vista - the command looks flat, but seems to be a little bit lighter than the other button in the toolbar. It seems that the style attribute at the command attribute does not have any effect.
Created attachment 66426 [details] screenshot of rcp mail template extended by a command displayed in the main toolbar attached screenshot shows our problem
Created attachment 67041 [details] Menu Contribution Toolbars v01 use the same method to create the menu contribution as used by the workbench window. PW
Eric, could you please review this patch? PW
Paul, it looks good to me (except for the spurious formatting changes..;-). +1
Released in HEAD >20070514 PW
In I20070516-0010 PW Robert, if you could check with this build as well that would be great.
I 've tested the rcp mail sample application plus our application with I20070517-0010. Looks good, buttons are displayed with the flat look. many thanks! Robert