CHAPTER 12Aligning Content

This chapter discusses design patterns that align text and content horizontally and vertically to their containing blocks. These alignment patterns work in the normal flow without using absolute or relative positioning.

The first three design patterns align content horizontally. The next three design patterns align content vertically. The last design pattern and the example at the end of the chapter are quite esoteric and have little practical application. I have included them to demonstrate the powerful capabilities built into the inline formatting context.

  • Text Indent shows how to indent the first line of text.
  • Hanging Indent shows how to create a hanging indent.
  • Horizontal-aligned Content shows how to align text ...

Get Pro CSS and HTML Design Patterns now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.