Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » theme variants not working on Text and Composite
theme variants not working on Text and Composite [message #84080] Tue, 22 April 2008 18:15 Go to next message
Patrick Turcotte is currently offline Patrick TurcotteFriend
Messages: 23
Registered: July 2009
Junior Member
Hi,

We are trying to use theming variants to change the background color of a ViewPart.

Theming is working, because when we change the value of the global (widget.background) background color in the
..properties file, we can see the result.

But if we set theming variant as

public void createPartControl(Composite parent){
// NOT WORKING
parent.setData(WidgetUtil.CUSTOM_VARIANT, "myvariant");

// NOT WORKING EITHER
Text text = new Text(parent, SWT.NONE);
text.setData(WidgetUtil.CUSTOM_VARIANT, "myvariant");
}

and we define, in .properties file

myvariant/widget.background: 227, 76, 21
myvariant/list.background: red

the result is of the same color as the default/global values.

using RAP-1.1.0-M3

Any help appreciated.

Thanks,

Patrick
Re: theme variants not working on Text and Composite [message #84169 is a reply to message #84080] Wed, 23 April 2008 07:20 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: rsternberg.innoopract.com

Hi Patrick,

it's right that in M3 theme variants do not work for some
widgets/theming keys. Composite is one of them, which is already fixed
in CVS HEAD and I'll also fix the Text bug right away. I'm sorry for the
inconvenience. We're currently working on the theming subsystem to make
it more flexible and I think it will stabilize in the next weeks.

Best regards,
Ralf

Patrick Turcotte wrote:
> We are trying to use theming variants to change the background color of
> a ViewPart.
>
> Theming is working, because when we change the value of the global
> (widget.background) background color in the .properties file, we can see
> the result.
>
> But if we set theming variant as
>
> public void createPartControl(Composite parent){
> // NOT WORKING
> parent.setData(WidgetUtil.CUSTOM_VARIANT, "myvariant");
>
> // NOT WORKING EITHER
> Text text = new Text(parent, SWT.NONE);
> text.setData(WidgetUtil.CUSTOM_VARIANT, "myvariant");
> }
>
> and we define, in .properties file
>
> myvariant/widget.background: 227, 76, 21
> myvariant/list.background: red
>
> the result is of the same color as the default/global values.
>
> using RAP-1.1.0-M3
>
> Any help appreciated.
>
> Thanks,
>
> Patrick
Re: theme variants not working on Text and Composite [message #84350 is a reply to message #84169] Wed, 23 April 2008 21:16 Go to previous messageGo to next message
Patrick Turcotte is currently offline Patrick TurcotteFriend
Messages: 23
Registered: July 2009
Junior Member
Hi Ralf,

Super!

I'll see if I can wrap my head around creating a target from CVS HEAD stuff.

Thanks for the good work!

Patrick
> Hi Patrick,
>
> it's right that in M3 theme variants do not work for some
> widgets/theming keys. Composite is one of them, which is already fixed
> in CVS HEAD and I'll also fix the Text bug right away. I'm sorry for the
> inconvenience. We're currently working on the theming subsystem to make
> it more flexible and I think it will stabilize in the next weeks.
>
> Best regards,
> Ralf
>
Re: theme variants not working on Text and Composite [message #84364 is a reply to message #84350] Wed, 23 April 2008 21:21 Go to previous message
Benjamin Muskalla is currently offline Benjamin MuskallaFriend
Messages: 237
Registered: July 2009
Senior Member
If you want to work the the latest and greatest stuff from CVS HEAD you
can just import them with the provided Team project set (See
eclipse.org/rap -> CVS). This allows you to compile the stuff against
the newer plugins.

Greets
Benny

Patrick Turcotte wrote:
> Hi Ralf,
>
> Super!
>
> I'll see if I can wrap my head around creating a target from CVS HEAD
> stuff.
>
> Thanks for the good work!
>
> Patrick
>> Hi Patrick,
>>
>> it's right that in M3 theme variants do not work for some
>> widgets/theming keys. Composite is one of them, which is already fixed
>> in CVS HEAD and I'll also fix the Text bug right away. I'm sorry for
>> the inconvenience. We're currently working on the theming subsystem to
>> make it more flexible and I think it will stabilize in the next weeks.
>>
>> Best regards,
>> Ralf
>>
Previous Topic:Wrong UI Thread
Next Topic:DateChooser
Goto Forum:
  


Current Time: Fri Apr 19 01:04:50 GMT 2024

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

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

Back to the top