Using Custom Class Selectors with ODS HTML

As we saw in the previous example, the special class selector .MyHeader in the FRACTALS.CSS file specifies a white foreground color and black background color for a header cell. Nothing in our previous example, however, caused ODS to point to the .MyHeader class selector, so we didn't see any headers with a black background in Figure 18.13.

When ODS HTML builds an HTML table definition for your output, it uses HTML class selectors to link the output to a set of CSS style properties. Here are some examples of the type of class selectors that ODS builds:

<table class="Table"> <th class="l b Header" scope="col">Gender</th> <th class="r b Header" scope="col">N Obs</th> <th class="l t Data">Male</th> <th ...

Get Output Delivery System: The Basics and Beyond 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.