Getting menu item to open new window

SWT Designer allows you to create the views, editors, perspectives, pref pages, composites, etc. that comprise Eclipse SWT & RCP applications and plug-ins.

Moderators: Konstantin.Scheglov, gnebling, Alexander.Mitin, jwren, Eric Clayberg

Getting menu item to open new window

Postby TMehrens » Tue May 22, 2007 9:18 am

First I am very new to java, eclipse, the RCP and instantiations designer. I have created a composite using designer and a new actionset using the PDE so I have a menu item to open it. My problem is I need a step-by-step example on how to get a window to come up with my composite in it when I click on the menu item. Any help will be apprecitated.
TMehrens
 
Posts: 7
Joined: Thu Feb 22, 2007 1:01 pm
Location: Helena, MT

Re: Getting menu item to open new window

Postby Eric Clayberg » Tue May 22, 2007 6:27 pm

TMehrens wrote:First I am very new to java, eclipse, the RCP and instantiations designer. I have created a composite using designer and a new actionset using the PDE so I have a menu item to open it. My problem is I need a step-by-step example on how to get a window to come up with my composite in it when I click on the menu item. Any help will be apprecitated.

Why did you create a Composite rather than a Shell or SWT app window?

If you have a Composite, you will need to wrapper it in a Shell in order to open it as a window.

Create a new app window or Shell, set its layout manager to FillLayout and then place an instance of your Composite within it.

BTW, general questions about how to use SWT & RCP should be directed to the Eclipse SWT & RCP newsgroups.
Eric Clayberg
Software Engineering Manager
Google
http://code.google.com/webtoolkit/download.html

Author: "Eclipse Plug-ins"
http://www.qualityeclipse.com
Eric Clayberg
Moderator
 
Posts: 4503
Joined: Tue Sep 30, 2003 6:39 am
Location: Boston, MA USA


Return to SWT Designer

Who is online

Users browsing this forum: No registered users and 2 guests