new TextDiffOptions()
Options for PDFNet.PDFDoc.appendTextDiffDocOpt
Methods
-
addIgnoreZonesForPage(regions, page_num)
-
Adds a collection of ignorable regions for the given page, an optional list of page areas not to be included in analysis
Parameters:
Name Type Description regions
Array.<Core.PDFNet.Rect> the zones to be added to the ignore list page_num
number the page number the added regions belong to Returns:
this object, for call chaining -
getColorA()
-
Gets the value ColorA from the options object The difference color for deletions
Returns:
an object in form {R: number, G: number, B: number}, the current value for ColorA.- Type
- object
-
getColorB()
-
Gets the value ColorB from the options object The difference color for insertions
Returns:
an object in form {R: number, G: number, B: number}, the current value for ColorB.- Type
- object
-
getCompareUsingZOrder()
-
Gets the value CompareUsingZOrder from the options object Whether to use z-order (aka paint order) when comparing text between A and B. On by default.
Returns:
whether to use z-order (aka paint order) when comparing text between A and B. On by default.- Type
- boolean
-
getOpacityA()
-
Gets the value OpacityA from the options object The difference opacity for deletions
Returns:
the current value for OpacityA in between 0.0 (transparent) and 1.0 (opaque).- Type
- number
-
getOpacityB()
-
Gets the value OpacityB from the options object The difference opacity for deletions
Returns:
the current value for OpacityB in between 0.0 (transparent) and 1.0 (opaque).- Type
- number
-
setColorA(color)
-
Sets the value for ColorA in the options object The difference color for deletions
Parameters:
Name Type Description color
object the new value for ColorA, in form {R: number, G: number, B: number} Returns:
this object, for call chaining -
setColorB(color)
-
Sets the value for ColorB in the options object The difference color for insertions
Parameters:
Name Type Description color
object the new value for ColorB, in form {R: number, G: number, B: number} Returns:
this object, for call chaining -
setCompareUsingZOrder(value)
-
Sets the value for CompareUsingZOrder in the options object Whether to use z-order (aka paint order) when comparing text between A and B. On by default.
Parameters:
Name Type Description value
boolean whether to use z-order (aka paint order) when comparing text between A and B. On by default. Returns:
this object, for call chaining -
setOpacityA(opacity)
-
Sets the value for OpacityA in the options object The difference opacity for deletions
Parameters:
Name Type Description opacity
number the new value for OpacityA in between 0.0 (transparent) and 1.0 (opaque) Returns:
this object, for call chaining -
setOpacityB(opacity)
-
Sets the value for OpacityB in the options object The difference opacity for deletions
Parameters:
Name Type Description opacity
number the new value for OpacityB in between 0.0 (transparent) and 1.0 (opaque) Returns:
this object, for call chaining