css中自定义字体

时间:2023-03-09 03:27:37
css中自定义字体

css代码如下:

@font-face {
font-family: 'HelveticaNeueLTPro-Th';
src: url('../fonts/HelveticaNeueLTPro-Th.eot');
src: url('../fonts/HelveticaNeueLTPro-Th.eot?#iefix') format('embedded-opentype'),
url('../fonts/HelveticaNeueLTPro-Th.woff') format('woff'),
url('../fonts/HelveticaNeueLTPro-Th.ttf') format('truetype'),
url('../fonts/HelveticaNeueLTPro-Th.svg#HelveticaNeueLTPro-Th') format('svg');
font-weight: normal;
font-style: normal;
} //使用
.aaaa{ font-family: "HelveticaNeueLTPro-Th"; }