�HTML – FONTS ��
Amity School of Engineering & Technology
Amity School of Engineering & Technology
�Set Font Size
You can set content font size using size attribute. The range of accepted values is from 1(smallest) to 7(largest). The default size of a font is 3.
Amity School of Engineering & Technology
�Relative Font Size
You can specify how many sizes larger or how many sizes smaller than the preset font size should be. You can specify it like <font size="+n"> or <font size="-n">
Amity School of Engineering & Technology
�Setting Font Face
You can set font face using face attribute but be aware that if the user viewing the page doesn't have the font installed, they will not be able to see it. Instead user will see the default font face applicable to the user's computer.
Amity School of Engineering & Technology
�Specify alternate font faces
A visitor will only be able to see your font if they have that font installed on their computer. So, it is possible to specify two or more font face alternatives by listing the font face names, separated by a comma.
<font face="arial,helvetica">
<font face="Lucida Calligraphy,Comic Sans MS,Lucida Console">
When your page is loaded, their browser will display the first font face available. If none of the given fonts are installed, then it will display the default font face Times New Roman.
Amity School of Engineering & Technology
�Setting Font Color
You can set any font color you like using color attribute. You can specify the color that you want by either the color name or hexadecimal code for that color.
Amity School of Engineering & Technology
�The <basefont> Element:
Amity School of Engineering & Technology
Amity School of Engineering & Technology
Supporting Browsers
�
Element | Chrome | IE | Firefox | Opera | Safari |
<basefont> | No | No | No | No | No |
Description. The HTML <basefont> tag defines the default font-family, font-size and color for the text in the HTML document. Since this tag was removed in HTML5, it is recommended that you use CSS properties such as font, font-family, font-size and color to format the text in the document.
Amity School of Engineering & Technology
Thanks
Amity School of Engineering & Technology