CSS基础知识梳理-font字体

来源:互联网 发布:linux命令行登录mysql 编辑:程序博客网 时间:2024/05/22 19:26
<!DOCTYPE html><html><head><meta charset="UTF-8"><title>css中的字体</title><style type="text/css">h1 {/*设置字体的尺寸*/font-size: medium;/*设置字体的风格,italic(斜体的字体样式),oblique(倾斜的字体样式)*/font-style: normal;/*所有小写字母转换成大写,但是尺寸要比一般字母小*/font-variant: normal;/*设置字体的粗细*/font-weight: bold;}h1.oblique {/*设置字体的尺寸*/font-size: medium;/*设置字体的风格,italic(斜体的字体样式),oblique(倾斜的字体样式)*/font-style: normal;font-variant: normal;font-weight: normal;}</style></head><body><h1>css font-family</h1><h1 class="oblique">css font-family</h1><p class="serif">This is a paragraph, shown in the Times New Roman font.</p><p class="sansserif">This is a paragraph, shown in the Arial font.</p></body></html>

0 0
原创粉丝点击