Skip to main content



      Home
Home » Eclipse Projects » Remote Application Platform (RAP) » FormToolbar renders a separator using ControlContributions
FormToolbar renders a separator using ControlContributions [message #550757] Wed, 04 August 2010 05:25 Go to next message
Eclipse UserFriend
Hi,

I like to add a control to the form's toolbar using a ControlContribution.
But additionally to the control a seperator is also drawn in the middle of
the control...

public void createPartControl(Composite parent) {
FormToolkit toolkit = new FormToolkit(parent.getDisplay());
final Form form = toolkit.createForm(parent);
form.setText("Form Header");
form.getBody().setLayout(new FillLayout());
toolkit.decorateFormHeading(form);

IToolBarManager mgr = form.getToolBarManager();
mgr.add(new ControlContribution("label") {

@Override
protected Control createControl(Composite parent) {
CLabel label = new CLabel(parent, SWT.NONE);
label.setText("Test");
return label;
}});

mgr.update(true);
}

This seems to be a bug. Anyone can confirm this?

Thanks,
Niels
Re: FormToolbar renders a separator using ControlContributions [message #551682 is a reply to message #550757] Mon, 09 August 2010 03:04 Go to previous messageGo to next message
Eclipse UserFriend
Most likely this is the same behaviour as in RCP. If this is not the
case, please feel free to file a bugzilla.

Regards
Rüdiger

On 04.08.2010 11:25, Niels Lippke wrote:
> Hi,
>
> I like to add a control to the form's toolbar using a
> ControlContribution. But additionally to the control a seperator is also
> drawn in the middle of the control...
>
> public void createPartControl(Composite parent) {
> FormToolkit toolkit = new FormToolkit(parent.getDisplay());
> final Form form = toolkit.createForm(parent);
> form.setText("Form Header");
> form.getBody().setLayout(new FillLayout());
> toolkit.decorateFormHeading(form);
>
> Path: build.eclipse.org!not-for-mail
> From: Miro <mkkratchounov@hotmail.com>
> Newsgroups: eclipse.technology.rap
> Subject: =?utf-8?Q?Re:=20No=20layout=20registered=20with=20default=20 id?=
> Date: Wed, 04 Aug 2010 11:08:55 -0400
> Organization: Eclipse Community Forums
> Lines: 6
> Message-ID: <i3bvq7$lhd$1@build.eclipse.org>
> References: <i0spol$2lp$1@build.eclipse.org>
> Reply-To: Miro <mkkratchounov@hotmail.com>
> NNTP-Posting-Host: node-www.eclipse.org
> Content-Type: text/plain; charset=utf-8; format=flowed
> X-Trace: build.eclipse.org 1280934535 22061 172.25.25.107 (4 Aug 2010
> 15:08:55 GMT)
> X-Complaints-To: news@build.eclipse.org
> NNTP-Posting-Date: Wed, 4 Aug 2010 15:08:55 +0000 (UTC)
> X-FUDforum: c7ed4ca4d6a4ff3b73a07e2176df25fb <550895>
> User-Agent: FUDforum Xref: build.eclipse.org eclipse.technology.rap:9813
>
> Hi,
>
> Open Run Configuration of your RAP application and then select the
> Bundles tab. Unselect the rap.demo bundles. This should fix your problem.
>
> Cheers,
> Miro


--
Rüdiger Herrmann
http://eclipsesource.com
Re: FormToolbar renders a separator using ControlContributions [message #551793 is a reply to message #551682] Mon, 09 August 2010 10:56 Go to previous message
Eclipse UserFriend
Hi,

this is good point. I ran the snippet within an RCP application and there is
no seperator.
Therefore I file Bug #322146.

Thanks,

Niels

"Rüdiger Herrmann" <rherrmann@eclipsesource.com> schrieb im Newsbeitrag
news:i3o99c$rbt$2@build.eclipse.org...
> Most likely this is the same behaviour as in RCP. If this is not the case,
> please feel free to file a bugzilla.
>
> Regards
> Rüdiger
>
> On 04.08.2010 11:25, Niels Lippke wrote:
>> Hi,
>>
>> I like to add a control to the form's toolbar using a
>> ControlContribution. But additionally to the control a seperator is also
>> drawn in the middle of the control...
>>
>> public void createPartControl(Composite parent) {
>> FormToolkit toolkit = new FormToolkit(parent.getDisplay());
>> final Form form = toolkit.createForm(parent);
>> form.setText("Form Header");
>> form.getBody().setLayout(new FillLayout());
>> toolkit.decorateFormHeading(form);
>>
>> Path: build.eclipse.org!not-for-mail
>> From: Miro <mkkratchounov@hotmail.com>
>> Newsgroups: eclipse.technology.rap
>> Subject: =?utf-8?Q?Re:=20No=20layout=20registered=20with=20default=20 id?=
>> Date: Wed, 04 Aug 2010 11:08:55 -0400
>> Organization: Eclipse Community Forums
>> Lines: 6
>> Message-ID: <i3bvq7$lhd$1@build.eclipse.org>
>> References: <i0spol$2lp$1@build.eclipse.org>
>> Reply-To: Miro <mkkratchounov@hotmail.com>
>> NNTP-Posting-Host: node-www.eclipse.org
>> Content-Type: text/plain; charset=utf-8; format=flowed
>> X-Trace: build.eclipse.org 1280934535 22061 172.25.25.107 (4 Aug 2010
>> 15:08:55 GMT)
>> X-Complaints-To: news@build.eclipse.org
>> NNTP-Posting-Date: Wed, 4 Aug 2010 15:08:55 +0000 (UTC)
>> X-FUDforum: c7ed4ca4d6a4ff3b73a07e2176df25fb <550895>
>> User-Agent: FUDforum Xref: build.eclipse.org eclipse.technology.rap:9813
>>
>> Hi,
>>
>> Open Run Configuration of your RAP application and then select the
>> Bundles tab. Unselect the rap.demo bundles. This should fix your problem.
>>
>> Cheers,
>> Miro
>
>
> --
> Rüdiger Herrmann
> http://eclipsesource.com
Previous Topic:HTML5 & E4 XWT?
Next Topic:Set Custom Style of Group-Frame
Goto Forum:
  


Current Time: Sun Jul 06 01:10:13 EDT 2025

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

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

Back to the top