TextLayerBuilder Constructor accepts an object of options.
parent
82f52d4e2d
commit
3b05275598
@ -398,8 +398,7 @@ window.onload = function () {
|
|||||||
$pdfContainer.append($textLayerDiv);
|
$pdfContainer.append($textLayerDiv);
|
||||||
|
|
||||||
page.getTextContent().then(function (textContent) {
|
page.getTextContent().then(function (textContent) {
|
||||||
var textLayer = new TextLayerBuilder($textLayerDiv.get(0), 0); //The second zero is an index identifying
|
var textLayer = new TextLayerBuilder({ textLayerDiv: $textLayerDiv.get(0) });
|
||||||
//the page. It is set to page.number - 1.
|
|
||||||
textLayer.setTextContent(textContent);
|
textLayer.setTextContent(textContent);
|
||||||
|
|
||||||
var renderContext = {
|
var renderContext = {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user