Here we will see how to change the font style like font name, color, size etc., in a sentence. Take the below sentence and will change the style.

How to change font style in a sentence using html font tag

    <div>
        <p>how to change font style in a sentence using html font tag</p>
    </div>

The above syntax will display the plain text without any style.

Font name (font face):

If we want to change font name in the sentence we will use face property to change the font names. See below example syntax

    <p>
        how to <font size="3" face="Broadway">change</font> 
        font style in a <font face="Magneto" size="4">sentence</font> using html font tag
    </p>

Font Size:

If we want to change font size in the sentence we will use size property to change the font size.

    <p>
        how to <font size="4">change</font> font style in a <font size="5">
        sentence</font> using html font tag
    </p>

Font Color:

If we want to use font color in a sentence we will use color property to change the colors in the sentence. We can use both name and color code as below.

    <p>
        how to <font color="red">change</font>font style in a
        <font color="#335bff">sentence</font> using html font tag
    </p>

Bold and italic:

We also change the font style as bold and italic for this we can use <b> and <i> tags.

    <p>how to <b>change</b> font style in a <i>sentence</i> using html font tag</p>

Underline:

We can use <u> tag for text underline

    <p>
        how to <u>change</u> font style in a <u><i>sentence</i>
        </u> using html font tag
    </p>

 

0 Comments1

Sorry, No more post.

Your Comment

Login To Comment

discard

By posting your Comment, you agree to the privacy policy and terms of service.