Home » Eclipse Projects » Remote Application Platform (RAP) » Painting background color for Combo box(How to paint the background color for the combo box arrow?)
Painting background color for Combo box [message #917105] |
Wed, 19 September 2012 20:29 |
Ronald So Messages: 198 Registered: April 2011 |
Senior Member |
|
|
Hi,
I have the following CSS code:
Combo,
Combo[BORDER] {
color: #4a4a4a;
background-color: #ecf1f7;
border: 1px solid #aaaaaa;
border-radius: 0px;
padding: 2px 5px;
background-image: none;
text-shadow: none;
box-shadow: none;
}
Combo.searchBox {
background-image: gradient(linear, left top, right top,
from( rgb(230, 230, 230) ),
to( rgb(180, 180, 180) )
);
border: 1px rgb(200, 200, 200);
}
Combo-Button.searchBox {
border-left: 0px;
background-color: rgb(220, 220, 220);
}
which I have registered the "searchBox" style with my combo widget.
This is what I get:
As you can see, the gradient works beautifully, but the arrow area is still white in color. I can't seem to be able to style that part of the widget. What did I do wrong?
Thanks,
Ronald
-
Attachment: combobox.png
(Size: 0.65KB, Downloaded 594 times)
|
|
|
Re: Painting background color for Combo box [message #917921 is a reply to message #917105] |
Thu, 20 September 2012 15:08 |
Tim Buschtoens Messages: 396 Registered: July 2009 |
Senior Member |
|
|
Hi.
As far as i can tell the result matches your CSS.
> Combo-Button.searchBox {
> border-left: 0px;
> background-color: rgb(220, 220, 220);
> }
If you don't want white, set "transparent" as background-color, or set a
gradient as background-image.
Greetings,
Tim
Am 19.09.2012 22:29, schrieb Ronald So:
> Hi,
>
> I have the following CSS code:
>
>
> Combo,
> Combo[BORDER] {
> color: #4a4a4a;
> background-color: #ecf1f7;
> border: 1px solid #aaaaaa;
> border-radius: 0px;
> padding: 2px 5px;
> background-image: none;
> text-shadow: none;
> box-shadow: none;
> }
>
> Combo.searchBox {
> background-image: gradient(linear, left top, right top,
> from( rgb(230, 230, 230) ),
> to( rgb(180, 180, 180) )
> );
> border: 1px rgb(200, 200, 200);
> }
>
> Combo-Button.searchBox {
> border-left: 0px;
> background-color: rgb(220, 220, 220);
> }
>
>
> which I have registered the "searchBox" style with my combo widget.
>
> This is what I get:
>
> As you can see, the gradient works beautifully, but the arrow area is still white in color. I can't seem to be able to style that part of the widget. What did I do wrong?
>
> Thanks,
> Ronald
>
>
--
Tim Buschtöns
Twitter: @EclipseRAP
Blog: http://eclipsesource.com/blogs/
Professional services for RAP and RCP?
http://eclipsesource.com/services/rap/
|
|
| | | |
Goto Forum:
Current Time: Thu Jan 23 18:24:19 GMT 2025
Powered by FUDForum. Page generated in 0.02986 seconds
|