web ⑩:Cascading Style Sheets (Review) #回来要看哪

咱们本篇文章要学习的内容呢,为以下部分:
web ⑩:Cascading Style Sheets (Review) #回来要看哪_第1张图片

一、

“CSS 背景” — --- 是以 background- 开头的一些样式声明

for example:

1.颜色做背景:

body 
{
background-color: grey;
}

咱们复习几个颜色单词啊~

grey   灰色
background-color: red; 
 或  orange;
       yellow;
       green;
       cyan;
       blue;
       purple;
       红橙黄绿青蓝紫

2.图像做背景:

background-image: url([imge-filename]);  

   background-position: center/top/bottom/left/right;

   background-repeat: no-repeat/repeat-x/repeat-y; 

   background-attachment: fixed/scroll;

其中,

其中background-image是首要的,
剩下是附带和与之相关的。

这样集中收集整理,便于把它们“一网打尽”,相关细节,需要自行去看“W3S”哦~~

二、

“CSS 文本” — --- 讲的是以 text- 开头的一些样式声明

用于定义网页中选定的文本样式:

text-indent: [size] 

text-align: left/right/center/justify(两端对齐) 

text-transform: none/uppercase/lowercase/capitalize; 

text-decoration: none/underline/overline/line-through/(blink);

复习单词环节①:

indent  缩进。
align  对齐。
transform  转换。
decoration  装饰。
underline   下划线
uppercase   大写。
lowercase   小写。

三、

“CSS 字体” — --- 讲的是以 font- 开头的一些样式声明

for example:

font-family: serif/sans-serif/monospace/cursive/fantasy; 

说明:
其中每一个都是一个字体家族。 可以同时指定一个具体的字体名和一个备用的字体家族,例如:

h1 {font-family: Georgia, serif;} 

如果找不到具体的Georgia字体,则选用serif家族的默认字体

复习单词环节②:

serif   衬线。
sans-serif   无衬线。
cursive   手写体

对于字体的几个样式:

font-style: normal/italic/(oblique); 

font-weight: normal/bold/bolder/lighter; 

font-size: [size];

复习单词环节③:

bold   加粗。

italic   斜体

四、

练习:

完成一个如下所示的网页要求

1、“章”标题CHAPTER 1 XXX 文本(text-)大写、加下划线、居中、灰色背景、宽50%;

2、文中的所有公式定义为一个类formula,并为其声明必要的(font-)样式;

3、页面底部的链接,要求鼠标指针移上、单击、过后呈现不同颜色。

web ⑩:Cascading Style Sheets (Review) #回来要看哪_第2张图片

咱们下期见~

有时间,xiao再来更新小练习呦 ฅ(˘ω˘ )ฅ

Bye~

你可能感兴趣的:(web ⑩:Cascading Style Sheets (Review) #回来要看哪)