Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

border-right-color property

Specifies the foreground color of the right border of an object.

CSS Backgrounds and Borders Module Level 3, Section 4.1

 

Syntax

border-right-color: <color> | currentColor | transparent | inherit

Property values

One of the following values:

color

A supported color value.

currentColor

The computed value of the color property.

transparent

Fully transparent. This keyword can be considered a shorthand for "transparent black" ("rgba(0,0,0,0)"), which is its computed value.

inherit

The value of this property is inherited from this object's parent.

CSS information

Applies ToAll elements
Mediavisual
Inheritedno
Initial ValuecurrentColor

Standards information

Remarks

Some browsers do not recognize color names, but all browsers should recognize RGB color values and display them correctly.

Examples

This example uses border-right-color to set the right border color to a different color than the rest of the border.


<body>
   <div class="box"></div>
   <div class="rounded"></div>
</body>

The CSS below sets the right border color for two div elements. The remaining border sides retain the color specified by the border-color property.

Two elements using the border-right-color property


.box {
   border-color: #BBBBBB;
   border-right-color: blue;
   border-style: solid;
   
}
.rounded {
   border-color: #C20000;
   border-right-color: #BBBBBB;
   border-style: dashed;	
   border-radius: 10px;
}

See also

CSSStyleDeclaration
currentStyle
defaults
runtimeStyle
style
border
border-top-color
border-left-color
border-bottom-color

 

 

Show:
© 2014 Microsoft