Open In App

Which property is used to make a font oblique ?

In this article, we will see the property that makes the font oblique. A CSS font-style property is used to style the given particular text in a normal, italic, or oblique face from its font-family. Using the font-style property, we can assign importance along with decorating the specific text. It helps to create a better user experience. 

In CSS, if we want to provide some different designs to any type of text, then we can make use of CSS font-style property.



Syntax:  

font-style: oblique

Example 1: This example illustrates the font-style whose value is set to oblique.






<!DOCTYPE html>
<html>
<head>
    <style>
    p.a {
        font-style: oblique;
    }
    </style>
</head>
  
<body>
    <h1 style="color:green;">GeeksforGeeks</h1>
    <h3>Oblique font-style Property</h3>
    <p class="a">GeeksforGeeks</p>
  
</body>
</html>

Output:

 

Example 2: This example illustrates the font-style whose value is set to oblique or h6 tag




<!DOCTYPE html>
<html>
<head>
    <style>
      h6.a {
          font-style: oblique;
      }
    </style>
</head>
  
<body>
    <h1 style="color:green;">GeeksforGeeks</h1>
    <h3>Oblique font-style Property</h3>
    <marquee><h6 class="a">GeeksforGeeks</h6></marquee>
</body>
</html>

Output:

 


Article Tags :