ComPDFKit Web SDK
    Preparing search index...

    Function setDefaultPrintOptions

    • Sets the default print options, merged with the existing ones. includeComments / includeAnnotations / maintainPageOrientation are booleans; margins is a string such as "0.5in" or "0.5in 0.4in 0.3in 0.2in"; pageScaling is 'fit' or 'actualSize'. There is no print settings dialog: includeAnnotations decides whether print() and the print button include annotations, margins sets the page margins, pageScaling decides whether pages fill the paper or keep their own size; includeComments / maintainPageOrientation have no effect and warn when true.

      Parameters

      Returns void

      instance.UI.setDefaultPrintOptions({ includeAnnotations: false, margins: '0.5in' });
      // Print each page at its own size instead of filling the paper
      instance.UI.setDefaultPrintOptions({ pageScaling: 'actualSize' });