Typography is a feature of Bootstrap for styling and formatting the text content. It is used to create customized headings, inline subheadings, lists, paragraphs, aligning, adding more design-oriented font styles and much more. Bootstrap support global settings for the font stack, Headings and Link styles to be used in the web app for every type of OS and Device to deliver the best user interface.
Typography can be used to create:
- Text and Paragraph font color, font type and alignment
- Other inline elements
Tags and class to implement typography feature in bootstrap:
- display headings: It is used to create better headings (larger font-size and lighter font-weight). There are four classes exists in display headings which are .display-1, .display-2, .display-3, and .display-4.
- lead: It is used to make a paragraph stand out i.e. visually better.
- mark: It is used to highlight the text content.
- initialism: It is used to render abbreviation in slightly small text size.
- blockquote: It is used to quote the text content.
- blockquote-footer: It is used to add the footer details for identifying the source of the Quote.
- text-center: It is used to align the text to the center.
- list-inline: It is used to make the element of list inline.
- text-truncate: It is used to shorten the longer text by truncating with an ellipsis.
- text-muted: It is used for text color, text-muted fades the text i.e. text greyed out.
- text-uppercase: It is used to transform text into uppercase.
- text-lowercase: It is used to transform text into lowercase.
- text-capitalize: It is used to transform text to capitalize first letter of each word leaving other letters in lowercase.
- .font-weight-bold: It sets the font weight to bold. It is used to display the importance of text.
- .font-weight-bolder: It sets the font weight to deep bold. It is used to display the importance of text.
- .font-italic: It sets the font style to italic.
- .font-weight-light: It sets the font weight to light.
- .font-weight-lighter: It sets the lighter font weight.
- .font-weight-normal: It sets the normal font size and weight.
- .lead: It makes the paragraph stand out.
- .small: It is used to create secondary subheadings.
- .text-left: It sets the left alignment of text.
- .text-*-left: It sets the left alignment of text on all screens (small, medium, large or xlarge).
- .text-break: It breaks the long string text into short text substrings.
Example 1: This example uses heading class to display the heading.
Example 2: This example uses <mark> tag to display the importance of text.
- Typography in Bootstrap
- p5.js | Typography | shearX() Function
- p5.js | Typography | shearY() Function
- Materialize CSS | Typography
- Include Bootstrap in AngularJS using ng-bootstrap
- Difference between bootstrap.css and bootstrap-theme.css
- Difference Between Bootstrap 3 and Bootstrap 4
- Difference between Bootstrap 4 and Bootstrap 5
- Beginning BootStrap (Part-1) | Introduction and Installation
- Beginning BootStrap (Part-2) | Grid System
- Bootstrap (Part-3) | Buttons, Glyphicons, Tables
- Bootstrap (Part-5) | DropDowns and Responsive Tabs
- Bootstrap (Part-4) | Vertical Forms, Horizontal Forms, Inline Forms
- How to get circular buttons in bootstrap 4 ?
- Bootstrap (Part-6) | Progress Bar and Jumbotron
- Bootstrap (Part-7) | Alerts , Wells, Pagination and Pager
- Bootstrap (Part-8) | Badges, Labels, Page Headers
- Bootstrap (Part-9) | Tooltips
- Difference between Bootstrap and AngularJS
- Bootstrap | Navigation Bar
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to firstname.lastname@example.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.