Omni Systems, Inc. Mif2Go User's Guide, Version 55

<< Prev | Next >>

> 22 Setting up CSS for HTML > 22.8 Customizing CSS properties > 22.8.2 Specifying CSS <body> tag properties

### 22.8.2 Specifying CSS <body> tag properties

You can specify a size value and the unit of measurement for the font-size property of the <body> tag in a Mif2Go-generated CSS file. Or, you can direct Mif2Go not to include a <body> tag entry in the CSS file; then you can substitute your own entry, in the project configuration file. Use one or the other method to specify a font size other than the default:

Custom font size and units

Custom <body> tag entry.

Custom font size and units

To specify font size and unit of measurement for the <body> tag:

[CSS]

; CssBodyFontSize = value for body {font-size: }, used as base for all

; em and ex sizes, and for font-size and line-height %, default 10.

CssBodyFontSize=10

; CssBodyFontUnit = units for body {font-size: }, default 0:

; 0=pt, 1=pc, 2=in, 3=cm, 4=mm, 7=px (pixels).

CssBodyFontUnit=0

CssBodyFontSize determines how values of relative measures em, ex , and % are computed for other CSS style properties. For example, 1.5em in a style property equals 1.5 times the value in pt (or in another non-relative unit) of the <body> tag font-size property.

CssBodyFontUnit should be an absolute unit of measurement rather than a relative unit.

Custom <body> tag entry

To prevent Mif2Go from automatically including a style entry for the <body> tag in a Mif2Go-generated CSS file:

[CSS]

; CssBodyFontTag = Yes (default, writes body { font-size:) or No

CssBodyFontTag=No

To specify the default font size yourself, provide a custom entry in macro section [CSSStartMacro]. For example:

[CSSStartMacro]

body { font-size: 11pt; margin: 0 0 0 0 }

See also:

§22.8.3 Specifying CSS size values and units of measurement

§22.8.4 Overriding styles in Mif2Go-generated CSS files