Book Image

LaTeX Cookbook

By : Stefan Kottwitz
Book Image

LaTeX Cookbook

By: Stefan Kottwitz

Overview of this book

LaTeX is a high-quality typesetting software and is very popular, especially among scientists. Its programming language gives you full control over every aspect of your documents, no matter how complex they are. LaTeX's huge amount of customizable templates and supporting packages cover most aspects of writing with embedded typographic expertise. With this book you will learn to leverage the capabilities of the latest document classes and explore the functionalities of the newest packages. The book starts with examples of common document types. It provides you with samples for tuning text design, using fonts, embedding images, and creating legible tables. Common document parts such as the bibliography, glossary, and index are covered, with LaTeX's modern approach.You will learn how to create excellent graphics directly within LaTeX, including diagrams and plots quickly and easily. Finally, you will discover how to use the new engines XeTeX and LuaTeX for advanced programming and calculating with LaTeX. The example-driven approach of this book is sure to increase your productivity.
Table of Contents (19 chapters)
LaTeX Cookbook
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Merging cells


As indicated in the table design advice of the last recipe, instead of repeating identical values in adjacent cells, you could leave the other cells empty if the reader would be able to understand that the same values apply.

We can support the meaning by merging cells and centering the cell value over the whole new width.

How to do it...

Merging and centering can be done horizontally, vertically, or both combined. We will start with the horizontal method, spanning cells over multiple columns. You can see this often, with table headers that apply to several columns. So, in this recipe, we will conflate header texts.

As modeling clay, we will take the differences between various LaTeX compilers. While LaTeX remains the same, the underlying TeX engine causes differences. We will arrange them now, using these steps:

  1. Specify the class. You could simply use the article class for now:

    \documentclass{article}
  2. Load the array package, which provides useful commands:

    \usepackage{array}
  3. Load the...