Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Pulldown menu: display label of a command
Pulldown menu: display label of a command [message #1064799] Fri, 21 June 2013 07:41 Go to next message
Axel RICHARD is currently offline Axel RICHARDFriend
Messages: 43
Registered: September 2010
Location: France
Member
Hi,

In a contributed toolbar, I contributed a pulldown menu with two commands contributed in the pulldown menu. When I click on a command contributed in the menu, I want to display the label of this command close to pulldown arrow.

1. Is it possible to do this ?

I have another problem with my contributed pulldown menu. I have no icon associated with it. So by default, the label of the pulldown menu is displayed. All others commands (which have icons) contributed in the same toolbar take the same width as the pulldown menu ! It is ugly.

2. Is it possible to set the size of the contributed commands widgets in a contributed toolbar ?

Thanks,


Axel Richard
Obeo
Re: Pulldown menu: display label of a command [message #1064868 is a reply to message #1064799] Fri, 21 June 2013 13:23 Go to previous messageGo to next message
Paul Webster is currently offline Paul WebsterFriend
Messages: 6859
Registered: July 2009
Location: Ottawa
Senior Member

On 06/21/2013 09:09 AM, Axel RICHARD wrote:
> Hi,
>
> In a contributed toolbar, I contributed a pulldown menu with two
> commands contributed in the pulldown menu. When I click on a command
> contributed in the menu, I want to display the label of this command
> close to pulldown arrow.
>
> 1. Is it possible to do this ?

You might have to try something with
org.eclipse.jface.window.DefaultToolTip.

>
> I have another problem with my contributed pulldown menu. I have no icon
> associated with it. So by default, the label of the pulldown menu is
> displayed. All others commands (which have icons) contributed in the
> same toolbar take the same width as the pulldown menu ! It is ugly.
>
> 2. Is it possible to set the size of the contributed commands widgets in
> a contributed toolbar ?

The icons take the same width as your label? Or the same height? Could
you please attach a small snapshot?

There's no way to control the size of contributed toolitem widgets.

PW


--
Paul Webster
http://wiki.eclipse.org/Platform_Command_Framework
http://wiki.eclipse.org/Command_Core_Expressions
http://wiki.eclipse.org/Platform_Expression_Framework
http://wiki.eclipse.org/Menu_Contributions
http://wiki.eclipse.org/Menus_Extension_Mapping
http://help.eclipse.org/helios/index.jsp?topic=/org.eclipse.platform.doc.isv/guide/workbench.htm


Re: Pulldown menu: display label of a command [message #1064872 is a reply to message #1064868] Fri, 21 June 2013 13:38 Go to previous messageGo to next message
Axel RICHARD is currently offline Axel RICHARDFriend
Messages: 43
Registered: September 2010
Location: France
Member
It's the same height, but the width is also modified.

I attached two screenshots : one without dropdown menu, and one with dropdown. One this with dropdown, you can see that all widgets contributed in toolbar have their height and wdth modified compare to this without dropdown.


Axel Richard
Obeo
Re: Pulldown menu: display label of a command [message #1064889 is a reply to message #1064872] Fri, 21 June 2013 14:10 Go to previous messageGo to next message
Paul Webster is currently offline Paul WebsterFriend
Messages: 6859
Registered: July 2009
Location: Ottawa
Senior Member

On 06/21/2013 09:38 AM, Axel RICHARD wrote:
> It's the same height, but the width is also modified.
>
> I attached two screenshots : one without dropdown menu, and one with dropdown. One this with dropdown, you can see that all widgets contributed in toolbar have their height and wdth modified compare to this without dropdown.
>

Thanks. There's no way to modify the height yourself (and that's what's
effecting the width). I'd replace it with an icon.

PW

--
Paul Webster
http://wiki.eclipse.org/Platform_Command_Framework
http://wiki.eclipse.org/Command_Core_Expressions
http://wiki.eclipse.org/Platform_Expression_Framework
http://wiki.eclipse.org/Menu_Contributions
http://wiki.eclipse.org/Menus_Extension_Mapping
http://help.eclipse.org/helios/index.jsp?topic=/org.eclipse.platform.doc.isv/guide/workbench.htm


Re: Pulldown menu: display label of a command [message #1064892 is a reply to message #1064889] Fri, 21 June 2013 14:19 Go to previous message
Axel RICHARD is currently offline Axel RICHARDFriend
Messages: 43
Registered: September 2010
Location: France
Member
Ok, thanks a lot for your help.

Axel Richard
Obeo
Previous Topic:Child menu of New menu is not showing In E4 RCP.
Next Topic:Reset perspective though command for perspective created by application model not showing any part i
Goto Forum:
  


Current Time: Fri Mar 29 15:20:01 GMT 2024

Powered by FUDForum. Page generated in 0.02544 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top