# Dynamic Appearance Properties

Some widgets visualize variable content, which must be dynamically reconstructed after each field value change. To define the way this content is evaluated, all widgets provide two types of properties – `VariableTextProperties` defining the text-specific properties, and `DynamicAppearanceCharacteristics` defining the geometry-specific properties.

* [VariableTextProperties Class](https://www.telerik.com/document-processing-libraries/documentation/libraries/radpdfprocessing/model/interactive-forms/dynamic-appearance-properties#variabletextproperties-class)

* [DynamicAppearanceCharacteristics Class](https://www.telerik.com/document-processing-libraries/documentation/libraries/radpdfprocessing/model/interactive-forms/dynamic-appearance-properties#dynamicappearancecharacteristics-class)

## VariableTextProperties Class

The `VariableTextProperties` class is used by [Widget annotations](https://www.telerik.com/document-processing-libraries/documentation/libraries/radpdfprocessing/model/annotations/widgets) to specify the properties needed for the dynamic construction of widget text. An instance of this class can also be found in the [FormField class](https://www.telerik.com/document-processing-libraries/documentation/libraries/radpdfprocessing/model/interactive-forms/form-fields/formfields), providing an easy way to ensure that all widgets created from this field use similar text properties.

The following table lists the available properties:

| Property              | Description                                                                                                                              |
| --------------------- | ---------------------------------------------------------------------------------------------------------------------------------------- |
| `HorizontalAlignment` | Gets or sets the text horizontal alignment.                                                                                              |
| `CharacterSpacing`    | Gets or sets the character spacing.                                                                                                      |
| `WordSpacing`         | Gets or sets the word spacing.                                                                                                           |
| `HorizontalScaling`   | Gets or sets the text horizontal scaling.                                                                                                |
| `Font`                | Gets or sets the font.                                                                                                                   |
| `FontSize`            | Gets or sets the font size. If zero, the size is automatically calculated to fit the available space in the widget annotation rectangle. |
| `TextRise`            | Gets or sets the text rise.                                                                                                              |
| `RenderingMode`       | Gets or sets the text rendering mode.                                                                                                    |
| `Fill`                | Gets or sets the text fill color.                                                                                                        |
| `Stroke`              | Gets or sets the text stroke color.                                                                                                      |
| `StrokeThickness`     | Gets or sets the text stroke thickness.                                                                                                  |
| `StrokeLineCap`       | Gets or sets the text stroke line cap.                                                                                                   |
| `StrokeLineJoin`      | Gets or sets the text stroke line join.                                                                                                  |
| `StrokeDashArray`     | Gets or sets the text stroke dash array.                                                                                                 |
| `StrokeDashOffset`    | Gets or sets the text stroke dash offset.                                                                                                |
| `MilterLimit`         | Gets or sets the text miter limit.                                                                                                       |

> important In **.NET Standard/.NET (Target OS: None)** environments, fonts beyond the [14 standard ones](https://www.telerik.com/document-processing-libraries/documentation/libraries/radpdfprocessing/concepts/fonts#standard-fonts) require a [FontsProvider implementation](https://www.telerik.com/document-processing-libraries/documentation/knowledge-base/pdfprocessing-implement-fontsprovider) to be resolved correctly.

## DynamicAppearanceCharacteristics Class

The `DynamicAppearanceCharacteristics` class is used by [VariableContentWidget](https://www.telerik.com/document-processing-libraries/documentation/libraries/radpdfprocessing/model/annotations/widgets#variablecontentwidget-class) and [SignatureWidget](https://www.telerik.com/document-processing-libraries/documentation/libraries/radpdfprocessing/model/annotations/widgets#signaturewidget-class) classes to specify the dynamic construction of widget geometry representation. It provides the following properties:

| Property      | Description                                                                                                                                                                                                                                                                                                     |
| ------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `Rotation`    | Gets or sets the rotation of the widget content.                                                                                                                                                                                                                                                                |
| `BorderColor` | Gets or sets the color of the Widget rectangle border. If `null`, no border is drawn. Takes effect only when an [AnnotationBorder](https://docs.telerik.com/devtools/document-processing/api/Telerik.Windows.Documents.Fixed.Model.Annotations.AnnotationBorder.html) is set to the widget's `Border` property. |
| `Background`  | Gets or sets the color of the Widget rectangle background. If `null`, no background is drawn.                                                                                                                                                                                                                   |

### ButtonAppearanceCharacteristics Class

The `ButtonAppearanceCharacteristics` class inherits `DynamicAppearanceCharacteristics` and is used by [TwoStateButtonWidget](https://www.telerik.com/document-processing-libraries/documentation/libraries/radpdfprocessing/model/annotations/widgets#twostatebuttonwidget-class) and [RadioButtonWidget](https://www.telerik.com/document-processing-libraries/documentation/libraries/radpdfprocessing/model/annotations/widgets#radiobuttonwidget-class) for dynamically constructing button appearances. It adds the following property to its parent class implementation:

| Property        | Description                                                       |
| --------------- | ----------------------------------------------------------------- |
| `NormalCaption` | The text drawn when the mouse is not interacting with the button. |

### PushButtonAppearanceCharacteristics Class

The `PushButtonAppearanceCharacteristics` class inherits `ButtonAppearanceCharacteristics` and is used by [PushButtonWidget](https://www.telerik.com/document-processing-libraries/documentation/libraries/radpdfprocessing/model/annotations/widgets#pushbuttonwidget-class) for dynamically constructing button appearances. It adds the following properties to its parent class implementation:

| Property                 | Description                                                                                                                                                                                                              |
| ------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `MouseOverCaption`       | The text drawn when the mouse is over the button.                                                                                                                                                                        |
| `MouseDownCaption`       | The text drawn when the mouse is pressed on the button.                                                                                                                                                                  |
| `NormalIconSource`       | [FormSource](https://www.telerik.com/document-processing-libraries/documentation/libraries/radpdfprocessing/model/formsource/overview) used for drawing a button icon when the mouse is not interacting with the widget. |
| `MouseOverIcon`          | [FormSource](https://www.telerik.com/document-processing-libraries/documentation/libraries/radpdfprocessing/model/formsource/overview) used for drawing a button icon when the mouse is over the widget.                 |
| `MouseDownIcon`          | [FormSource](https://www.telerik.com/document-processing-libraries/documentation/libraries/radpdfprocessing/model/formsource/overview) used for drawing a button icon when the mouse is pressed on the widget.           |
| `IconAndCaptionPosition` | Specifies how to position the button icon relative to the button caption.                                                                                                                                                |
| `IconFitOptions`         | Provides options specifying how to position and whether or how to scale the icon within the available space in the annotation rectangle.                                                                                 |

## See Also

* [PDF Annotation Widgets](https://www.telerik.com/document-processing-libraries/documentation/libraries/radpdfprocessing/model/annotations/widgets)
* [AcroForm](https://www.telerik.com/document-processing-libraries/documentation/libraries/radpdfprocessing/model/interactive-forms/acroform)
* [FormSource](https://www.telerik.com/document-processing-libraries/documentation/libraries/radpdfprocessing/model/formsource/overview)
