GenerateAppearances() Method

Definition

Namespace Broadside.Forms
Assembly Broadside.dll

Regenerates the normal appearance of every widget from the field's current Value, as an interactive processor does for variable text.

public void GenerateAppearances()

Remarks

ISO 32000-2 §12.7.4.3. Each widget gets a new form XObject as its normal appearance (AP N; other appearance states are dropped), whose bounding box is the widget rectangle's size, whose resources are copied from the default resources (DR) the font was found in, and whose content is the clause's: the MK background and border (in the border style), then /Tx BMC q, a clip to the inside of the border, BT, the default appearance (its Tf with the size computed when auto-sized, its colour, its other operators as written), a Tm per line whose translation positions the text, and ET Q EMC. The widget's MK rotation (R) rotates the appearance (§12.5.6.19, Table 192).

The text follows the quadding (Quadding) on one line, or wraps between words in a multi-line field; a comb field spaces at most MaxLength characters evenly, one per cell; a password field shows asterisks. An auto-sized font fits the field. Characters the default appearance font cannot encode are shown in a TrueType font found by the engine's font resolvers (configure UseStandard14Fonts() for Liberation Sans), embedded as a subset Type 0 font (§9.7, §9.9.2) with a ToUnicode CMap (§9.10.3): one subset per font program, shared by every field of the document that needs it and reduced to the glyphs used when the document is saved. Rich text (IsRichText) is shown as plain text.