1
0
Fork 0
mirror of https://github.com/mozilla/pdf.js.git synced 2025-04-26 10:08:06 +02:00

don't render highlight/underline/squiggly/strikeout annotations that doesn't have popup

This commit is contained in:
Xiliang Chen 2016-02-22 13:10:20 +13:00
parent 45fea8808e
commit 6762ff2fd6
2 changed files with 12 additions and 4 deletions

View file

@ -797,6 +797,7 @@ var HighlightAnnotation = (function HighlightAnnotationClosure() {
Annotation.call(this, parameters);
this.data.annotationType = AnnotationType.HIGHLIGHT;
this.data.hasPopup = parameters.dict.has('Popup');
// PDF viewers completely ignore any border styles.
this.data.borderStyle.setWidth(0);
@ -812,6 +813,7 @@ var UnderlineAnnotation = (function UnderlineAnnotationClosure() {
Annotation.call(this, parameters);
this.data.annotationType = AnnotationType.UNDERLINE;
this.data.hasPopup = parameters.dict.has('Popup');
// PDF viewers completely ignore any border styles.
this.data.borderStyle.setWidth(0);
@ -827,6 +829,7 @@ var SquigglyAnnotation = (function SquigglyAnnotationClosure() {
Annotation.call(this, parameters);
this.data.annotationType = AnnotationType.SQUIGGLY;
this.data.hasPopup = parameters.dict.has('Popup');
// PDF viewers completely ignore any border styles.
this.data.borderStyle.setWidth(0);
@ -842,6 +845,7 @@ var StrikeOutAnnotation = (function StrikeOutAnnotationClosure() {
Annotation.call(this, parameters);
this.data.annotationType = AnnotationType.STRIKEOUT;
this.data.hasPopup = parameters.dict.has('Popup');
// PDF viewers completely ignore any border styles.
this.data.borderStyle.setWidth(0);