addFont method

dynamic addFont(
  1. dynamic postScriptName,
  2. dynamic fontName,
  3. dynamic fontStyle,
  4. dynamic fontWeight, [
  5. dynamic encoding,
])

Add a custom font to the current instance.

@param {string} postScriptName PDF specification full name for the font. @param {string} id PDF-document-instance-specific label assinged to the font. @param {string} fontStyle Style of the Font. @param {number | string} fontWeight Weight of the Font. @param {Object} encoding Encoding_name-to-Font_metrics_object mapping. @function @instance @memberof jsPDF# @name addFont @returns {string} fontId encoding = encoding || 'Identity-H';

Implementation

external addFont(postScriptName, fontName, fontStyle, fontWeight, [encoding]);