CSS font code generator →
Fonts are important part of our html page. We can manage the style property of our fonts using style sheet. We will use internal style sheet to set the property values of our fonts. We will discuss each font property here and its possible values. At the end you can see the demo and html code of the style sheet used.
Font Family
Let us start with font type or family by saying what style of font to be used. We can use any supported font. Here is how we will set the font family using CSS.
P { font-family: "New Century Schoolbook", Times, serif }
We can be used to display fonts in two options one is normal and other is SMALL-CAPS
P { font-variant: small-caps}
With small-caps all fonts will be displayed in upper case ( capital letters ) and with upper case letter in slightly higher in height.
We can adjust the gap between lines ( line spacing ) by using line-height.
P{ line-height:1.7em}
We can combine all above internal styles in to one declaration and keep it inside the page. Same code we can use for CSS also.
DEMO : Font Style using internal Style →
Now here is the total style code