Home » Eclipse Projects » Remote Application Platform (RAP) » How to style View header?(CSS related questions)
| | | | |
Re: How to style View header? [message #900607 is a reply to message #900434] |
Tue, 07 August 2012 18:32 |
Ronald So Messages: 198 Registered: April 2011 |
Senior Member |
|
|
Ivan,
Thanks for the link but I am trying to keep all my settings in CSS. After trying the CTabItem style,
CTabItem {
font: normal bold 15px Trebuchet, Arial, sans-serif;
color: #ffffff;
background-color: #005596;
background-image: none;
padding: 10px 25px;
spacing: 0px;
text-shadow: none;
}
CTabItem:selected {
color: #005596;
background-image: gradient(linear, left top, left bottom,
from( #0000ff ),
color-stop( 10%, #ffffff) ),
to( #ffffff )
);
}
It seems like RAP honors the font, padding, spacing, and text-shadow without a problem. However, "color", "background-color", and "background-image" are not being honored.
I have attached how the UI renders when the tabs are being selected with the code above.
Thanks,
Ronald
|
|
|
Re: How to style View header? [message #900617 is a reply to message #900607] |
Tue, 07 August 2012 19:20 |
Ivan Furnadjiev Messages: 2429 Registered: July 2009 Location: Sofia, Bulgaria |
Senior Member |
|
|
Roland,
that's true, because these properties are overrided by the Workbench
theme - set background, background (selection) gradient by code. If you
search somewhere in the DefaultTabFolder or PaneFolder classes you will
find the places where these properties are set. In RAP, the properties
set by the code always override the same properties set by RAP theming.
HTH,
Ivan
On 8/7/2012 9:32 PM, Ronald So wrote:
> Ivan,
>
> Thanks for the link but I am trying to keep all my settings in CSS. After trying the CTabItem style,
>
>
> CTabItem {
> font: normal bold 15px Trebuchet, Arial, sans-serif;
> color: #ffffff;
> background-color: #005596;
> background-image: none;
> padding: 10px 25px;
> spacing: 0px;
> text-shadow: none;
> }
>
> CTabItem:selected {
> color: #005596;
> background-image: gradient(linear, left top, left bottom,
> from( #0000ff ),
> color-stop( 10%, #ffffff) ),
> to( #ffffff )
> );
> }
>
>
> It seems like RAP honors the font, padding, spacing, and text-shadow without a problem. However, "color", "background-color", and "background-image" are not being honored.
>
> I have attached how the UI renders when the tabs are being selected with the code above.
>
> Thanks,
> Ronald
--
Ivan Furnadjiev
Twitter: @EclipseRAP
Blog: http://eclipsesource.com/blogs/
Professional services for RAP and RCP?
http://eclipsesource.com/services/rap/
|
|
| |
Re: How to style View header? [message #900668 is a reply to message #900619] |
Wed, 08 August 2012 06:21 |
Ivan Furnadjiev Messages: 2429 Registered: July 2009 Location: Sofia, Bulgaria |
Senior Member |
|
|
Roland,
currently there is no workaround. If a property is set by the code it
takes precedence. From my point of view this is not a bug (this is how
workbench theming works) and there is no chance for improvement in this
direction for 1.5.1. Sorry.
Best,
Ivan
On 8/7/2012 10:41 PM, Ronald So wrote:
> Ivan,
>
> I understand that the code will override CSS settings, but is it a
> desirable behavior? With this limitation, developers are pretty much
> handcuffed by whatever colors that the code is using, and the color
> may not go along with the rest of the CSS settings we set for other
> components. Is there a way to relax it, or is it a big fix that there
> is no hope to get in 1.5.1 time frame even if a bug is logged?
>
> Thanks,
> Ronald
>
--
Ivan Furnadjiev
Twitter: @EclipseRAP
Blog: http://eclipsesource.com/blogs/
Professional services for RAP and RCP?
http://eclipsesource.com/services/rap/
|
|
|
Goto Forum:
Current Time: Mon Jan 20 10:35:18 GMT 2025
Powered by FUDForum. Page generated in 0.03868 seconds
|