HandWrittenSignatureSettings

23 Sep 20253 minutes to read

The HandWrittenSignatureSettings module is used to provide the properties to handwritten signature.

<div id="pdfViewer" style="height: 100%;width: 100%;"></div>
 let viewer: PdfViewer = new PdfViewer();
 // Change the hand written signature settings.
 viewer.handWrittenSignatureSettings = {
     signatureItem: [
         'Signature',
         'Initial'
     ],
     saveSignatureLimit: 1,
     saveInitialLimit: 1,
     opacity: 1,
     strokeColor: '#000000',
     width: 150,
     height: 100,
     thickness: 1,
     offset: { x:0, y:0 },
     pageNumber: 1,
     fontFamily: 'Helvetica',
     canSave: false,
     typeSignatureFonts: ['arial']
     annotationSelectorSettings: {
         selectionBorderColor: '',
         resizerBorderColor: 'black',
         resizerFillColor: '#FF4081',
         resizerSize: 8,
         selectionBorderThickness: 1,
         resizerShape: 'Circle',
         selectorLineDashArray: [],
         resizerLocation: AnnotationResizerLocation.Corners | AnnotationResizerLocation.Edges,
         resizerCursorType: null
     },
     allowedInteractions: ['None'],
     signatureDialogSettings: {
         displayMode: DisplayMode.Draw | DisplayMode.Text | DisplayMode.Upload, hideSaveSignature: false
     },
     initialDialogSettings: {
         displayMode: DisplayMode.Draw | DisplayMode.Text | DisplayMode.Upload,
     hideSaveSignature: false
     }
 };
 viewer.appendTo("#pdfViewer");

Properties

annotationSelectorSettings AnnotationSelectorSettingsModel

specifies the annotation selector settings of the annotation.

canSave boolean

Allows saving of programmatically added signatures.

Defaults to false

fontFamily string

Gets or sets the font family for text signature.

Defaults to ‘Helvetica’

height number

specified the height of the annotation.

initialDialogSettings SignatureDialogSettingsModel

Get or set the initialDialogSettings for Handwritten initial.

offset IPoint

Gets or sets the signature offset.

Defaults to {x:0,y:0}

opacity number

specifies the opacity of the annotation.

pageNumber number

Gets or sets the signature page number.

Defaults to 1

path string

Gets or sets the path of the signature.

Defaults to ’’

saveInitialLimit number

Gets or sets the save initial limit of the initial. By default value is 1 and maximum limit is 5.

saveSignatureLimit number

Gets or sets the save signature limit of the signature. By default value is 1 and maximum limit is 5.

signatureDialogSettings SignatureDialogSettingsModel

Get or set the Signature DialogSettings for Handwritten signature.

signatureItem SignatureItem[]

Provide option to define the required signature items to be displayed in signature menu.

strokeColor string

specifies the stroke color of the annotation.

thickness number

specified the thickness of the annotation.

typeSignatureFonts { : }

Options to set the type signature font name with respective index and maximum font name limit is 4 so key value should be 0 to 3.

width number

specified the width of the annotation.