Skip to main content



      Home
Home » Eclipse Projects » Remote Application Platform (RAP) » RAP Theming (Focus)
RAP Theming (Focus) [message #654799] Thu, 17 February 2011 03:36 Go to next message
Eclipse UserFriend
Hello,

We're using CSS in our RAP product to enhance the user-interface elements using themes.

How do we implement the behavior in CSS to mimic the colored-border[ORANGE] when focus is GAINED to the control, and when focus is LOST it should color to default color[GRAY].

We want to implement this on following controls

Text, Combo, CCombo, DateTime, Spinner, etc.



Thanks,
Sudesh

[Updated on: Thu, 17 February 2011 03:37] by Moderator

Re: RAP Theming (Focus) [message #654840 is a reply to message #654799] Thu, 17 February 2011 05:31 Go to previous messageGo to next message
Eclipse UserFriend
Hi Sudesh,
you could try the following:
1. Define custom variants for "focused" and "unfocused" state:
Combo.focused, Text.focused {
border: border: 1px solid green;
}
Combo.unfocused, Text.unfocused {
border: border: 1px solid red;
}
2. Add FocusListener to the control and switch the theming custom
variant like:
combo.setData( WidgetUtil.CUSTOM_VARIANT, "focused" );
HTH,
Ivan

On 2/17/2011 10:36 AM, Sudesh Bulathsinhala wrote:
> Hello,
>
> We're using CSS in our RAP product to enhance the user-interface
> elements using themes.
>
> How do we implement the behavior in CSS to mimic the
> colored-border[ORANGE] when focus is GAINED to the control, and when
> focus is LOST it should color to alternative color[GRAY].
>
> We want to implement this on following controls
>
> Text, Combo, CCombo, DateTime, Spinner, etc.
>
>
>
> Thanks,
> Sudesh
>
Re: RAP Theming (Focus) [message #655274 is a reply to message #654840] Fri, 18 February 2011 17:18 Go to previous message
Eclipse UserFriend
Hi Ivan,

Thanks, it's working as expected.

Regards,
Sudesh
Previous Topic:HowTo style BUTTON correctly - is there a bug or feature?
Next Topic:RAP Theming CSS: How to Table-Cell style-type?
Goto Forum:
  


Current Time: Sun Jul 27 11:54:15 EDT 2025

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

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

Back to the top