Paragraph Height (PHE)

The PHE is a substructure of the PAP and the PAPX FKP and is also stored in the PLCFPHE.

b10b16fieldtypesizebitfieldcomment
00fSpareshort:10001reserved
  fUnkshort:10002PHE entry is invalid when == 1
  fDiffLinesshort:10004when 1, total height of paragraph is known but lines in paragraph have different heights.
  *short:500F8reserved
  clMacshort:8FF00when fDiffLines is 0 is number of lines in paragraph
22 short  reserved
44dxaCollong  width of lines in paragraph
88dymLinelong  when fDiffLines is 0, is height of every line in paragraph in pixels
88dymHeightlong  when fDiffLines is 1, is the total height in pixels of the paragraph

If the PHE is stored in a PAP whose fTtp field is set (non-zero), the following structure is used:

b10b16fieldtypesizebitfieldcomment
00fSpareshort:10001reserved
  fUnkshort:10002PHE entry is invalid when == 1
  dcpTtpNextshort:30 if not == 0, used as a hint when finding the next row
44dxaCollong   
88dymTableHeightlong  height of table row

cbPHE (the count of bytes of PHE) is 12.

If there is no paragraph height information stored for a paragraph, all of the fields in the PHE are set to 0. If a paragraph contains more than 127 lines, the clMac, dylLine variant cannot be used, so fDiffLines must be set to 1 and the total size of the paragraph stored in dylHeight. If a paragraph height is greater than 32767 twips, the height cannot be represented by a PHE so all fields of the PHE must be set to 0.

If a new Word file is created, the PHE of every papx fkp entry created to describe the paragraphs of the file should be set to 0. If a Word file is altered in place (a character of the file changed to a new character or a property changed), the paragraph containing the change must have its papx.phe field set to 0. If this paragraph is in a table row, the PHE in the papx at the end of the row (indicated by fInTable) must also be set to 0.