亚洲乱码中文字幕综合,中国熟女仑乱hd,亚洲精品乱拍国产一区二区三区,一本大道卡一卡二卡三乱码全集资源,又粗又黄又硬又爽的免费视频

純CSS3實(shí)現(xiàn)的陰影效果

  發(fā)布時(shí)間:2014-12-24 14:55:39   作者:佚名   我要評(píng)論
這篇文章主要介紹了純CSS3實(shí)現(xiàn)的陰影效果的方法及示例代碼,非常的實(shí)用,這里推薦給大家。

    早上沒事干,感覺字體陰影的效果還是好看的,那么就來一個(gè)小demo吧!

1、這是html 簡單的有一個(gè)標(biāo)簽或者盒子都可以


復(fù)制代碼
代碼如下:

<div class="demo11">我愛考試</div>

2、css樣式,用css3編寫樣式,感覺還不錯(cuò)。


復(fù)制代碼
代碼如下:

.demo11 {
border: 1px dashed #f2b;
height: 150px;
width: 250px;
text-align: center;
line-height: 150px;
margin: 0 auto;
font-size: 50px;
color: orange;
text-shadow: 1px 1px rgba(197, 223, 248,0.8),2px 2px rgba(197, 223, 248,0.8),3px 3px rgba(197, 223, 248,0.8),4px 4px rgba(197, 223, 248,0.8),5px 5px rgba(197, 223, 248,0.8),6px 6px rgba(197, 223, 248,0.8);
}

3、附上一張效果圖

  一個(gè)簡單的字體陰影效果就是這么出來的,其中還可以定義字體的樣式(font-family)效果會(huì)更好的哦!

以上呢,這就是字體外陰影的一個(gè)小demo;

下面呢,來看一下內(nèi)陰影吧,

1、html樣式


復(fù)制代碼
代碼如下:

<div class="block black" style="background-color: #444;">
<span style="color: rgba(0, 0, 0, 0.5);">
I love test
我愛考試
</span>
</div></p> <p><br clear="all"></p> <p><div class="block white">
<span style="color: rgba(128, 128, 128, 0.5);">
I love test
我愛考試
</span>
</div>

2、簡單的css樣式


復(fù)制代碼
代碼如下:

<style>
.block {
font-size: 2em;
font-weight: bold;
margin: 2px;
padding: 2px;
border: solid #AAA 1px;
display: inline-block;
}
.black {
text-shadow: 1px 1px 2px #888, 0 0 0 #000;
}</p> <p>.white {
text-shadow: 1px 1px 2px #FFF, 0 0 0 #000;
}
</style>

  都是比較簡單的樣式,很容易理解吧!

  附上小圖一張,供參考了!

這樣呢,內(nèi)陰影也就出來了,雖然不是很好看,但是也挺實(shí)用的,嘻嘻!

相關(guān)文章

最新評(píng)論