Skip to main content



      Home
Home » Eclipse Projects » Eclipse Platform » JFace Adding a Combo to a ToolBarManager
JFace Adding a Combo to a ToolBarManager [message #286098] Thu, 02 June 2005 09:40 Go to next message
Eclipse UserFriend
Originally posted by: alastair.gulland.gulland.com

Hi

I am using the jface ToolBarManager and so far I can add icons to this
bar. I can add a combo using,

ToolBar bar = toolBarManager.getControl();
Combo combo = new Combo(bar, SWT.DEFAULT );
combo.add ("Item 1");
combo.add ("Item 2");
combo.pack ();

however the combo appears on the LHS and sits over the buttons. How do I
get it to be added to the right of the buttons?

My class is extending ApplicationWindow and the ToolBarManager is created
by overriding the createToolBarManager method.

thanks for any tips

AL
Re: JFace Adding a Combo to a ToolBarManager [message #286100 is a reply to message #286098] Thu, 02 June 2005 09:47 Go to previous message
Eclipse UserFriend
For an (swt level) example of this see
http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.swt.sni ppets/src/org/eclipse/swt/snippets/Snippet58.java?rev=HEAD&a mp;content-type=text/vnd.viewcvs-markup .

Grant

"AL" <alastair.gulland@gulland.com> wrote in message
news:22714f725b24f358addec45e11bb1062$1@www.eclipse.org...
> Hi
>
> I am using the jface ToolBarManager and so far I can add icons to this
> bar. I can add a combo using,
>
> ToolBar bar = toolBarManager.getControl();
> Combo combo = new Combo(bar, SWT.DEFAULT );
> combo.add ("Item 1");
> combo.add ("Item 2");
> combo.pack ();
>
> however the combo appears on the LHS and sits over the buttons. How do I
> get it to be added to the right of the buttons?
>
> My class is extending ApplicationWindow and the ToolBarManager is created
> by overriding the createToolBarManager method.
>
> thanks for any tips
>
> AL
>
Previous Topic:RC1 problem
Next Topic:what's the difference between workbench page and perspective
Goto Forum:
  


Current Time: Tue Jul 15 16:31:52 EDT 2025

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

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

Back to the top