CSSフォントバリアントプロパティ
CSSのfont-variantプロパティは、font-variant-caps、font-variant-numeric、font-variant-alternates、font-variant-ligatures、およびfont-variant-east-asianのプロパティの省略形です。次の値があります-
font-variant: normal|small-caps|initial|inherit;
例
font-variantプロパティを実装する例を見てみましょう-
<!DOCTYPE html>
<html>
<head>
<style>
body {
background-image: linear-gradient(to right, yellow,orange,yellow,green,blue,indigo,violet);
}
.demo {
text-decoration: overline;
text-decoration-color: yellow;
font-variant:normal;
}
</style>
</head>
<body>
<h1>Examination Details</h1>
<p class="demo">Exam on 20th December.</p>
<p class="demo2">Exam begins at 9AM.</p>
</body>
</html> 出力
例
別の例を見てみましょう-
<!DOCTYPE html>
<html>
<head>
<style>
.demo {
text-decoration: overline underline;
text-decoration-color: blue;
font-variant: small-caps;
}
</style>
</head>
<body>
<h1>Details</h1>
<p class="demo">Examination Center near ABC College.</p>
<p class="demo2">Exam begins at 9AM.</p>
</body>
</html> 出力
-
CSS空白プロパティ
空白プロパティを使用して、要素内の空白を操作します: 例 <!DOCTYPE html> <html> <head> <style> p.demo1 { white-space: normal; } &nbs
-
CSSの書き込みモードプロパティ
書き込みモードプロパティは、テキストの行を水平方向に配置するか垂直方向に配置するかを設定するために使用されます。プロパティ値は-です writing-mode: horizontal-tb|vertical-rl|vertical-lr; 例 <!DOCTYPE html> <html> <head> <style> p { writing-mode: vertical-rl; } </style> </head> <body> <h1>Demo Heading</h