XF: Extended Format (E0h) [PXL 2.0]

A BIFF file can contain as many XF records as necessary to describe the different cell formats in a workbook. The XF record stores formatting properties for cells. The ixfe of a cell record (BLANK, LABEL, NUMBER, and so on) points to a cell XF record.

Record Data

Offset
Name
Size
Contents
0 ixfnt 2 Index to FONT record
4 ixnf 2 Index to FORMAT record plus 230
6 fattributes 4 Unused, set to 0xFFFF
10 fBaseAttr 2 Base attribute flags
12 fTextAttr 2 Text attribute flags
14 icvFore 2 Background color of cell
16 icvFill 2 Unused
18 bRight 1 Right border style
19 bTop 1 Top border style
20 bLeft 1 Left border style
21 bBottom 1 Bottom border style
20 backstyle 1 Unused
21 borderstyle 1 Unused

Parameters

fBaseAttr
The fBaseAttr flags are packed into the first four bits of this parameter:
Bit
Size
Name
Contents
0 1 m_cFixed Unused
1 1 m_fLocked Unused
2 1 m_Hidden Unused
3 1 m_f123Prefix Unused

fTextAttr
The fTextAttr flags are packed into this parameter in the following way:
Bit
Size
Name
Contents
0 3 m_nAlignment Horizontal alignment
3 1 m_fWordWrap True if “Wrap Text” is on
4 3 m_nVertAlign Vertical alignment
7 1 m_fJustLast Unused
8 1 m_fTop Unused
9 1 m_fLeft Unused
10 1 m_fBot Unused
11 1 m_fRight Unused
12 4 Reserved Reserved