Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Difference between border ridge and groove styles

Tags:

html

css

I want to know the difference between border styles- ridge and groove. When i used them, i was not able to spot the difference between the two. I cannot upload the image since i have not reached level 10 to make it more clear. Here's the code:

border-style: groove ridge dashed groove;
like image 259
Mark Avatar asked Jan 28 '15 09:01

Mark


People also ask

What is Border Style Ridge?

ridge - Defines a 3D ridged border. The effect depends on the border-color value. inset - Defines a 3D inset border. The effect depends on the border-color value. outset - Defines a 3D outset border.

What are the different border styles?

border-style: dotted solid double dashed; top border is dotted. right border is solid. bottom border is double. left border is dashed.

What is the meaning of border style?

The border-style shorthand CSS property sets the line style for all four sides of an element's border.

What is border style property explain the different border style property?

The border-style property is a shorthand for the following CSS properties: CSS border-bottom-style Property: It s used to set the style of the bottom border of an element. CSS border-top-style Property: It is used to specify the style of the top border.


1 Answers

It's border shadow position:

Ridge: from top left
Groove: from bottom right

div {
  padding: 10px;
  margin: 10px;
  float: left;
  background-color: white;
}
.wrap {
  background-color: #ffdddd;
}
#ridge {
  border-width: 5px;
  border-style: ridge;
  margin-right: 1px;
}
#groove {
  border-width: 5px;
  border-style: groove;
  margin-left: 1px;
}
<div class="wrap">
  <div id="ridge">ridge</div>
  <div id="groove">groove</div>
</div>
like image 58
Justinas Avatar answered Sep 19 '22 00:09

Justinas