mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-22 16:18:08 +02:00
Merge pull request #14162 from brendandahl/indent-stepper
Indent the stepper on save/restore.
This commit is contained in:
commit
38e5360533
2 changed files with 9 additions and 1 deletions
|
@ -292,6 +292,7 @@ const Stepper = (function StepperClosure() {
|
|||
this.breakPoints = initialBreakPoints;
|
||||
this.currentIdx = -1;
|
||||
this.operatorListIdx = 0;
|
||||
this.indentLevel = 0;
|
||||
}
|
||||
|
||||
init(operatorList) {
|
||||
|
@ -382,8 +383,14 @@ const Stepper = (function StepperClosure() {
|
|||
table.appendChild(charCodeRow);
|
||||
table.appendChild(fontCharRow);
|
||||
table.appendChild(unicodeRow);
|
||||
} else if (fn === "restore") {
|
||||
this.indentLevel--;
|
||||
}
|
||||
line.appendChild(c("td", fn));
|
||||
line.appendChild(c("td", " ".repeat(this.indentLevel * 2) + fn));
|
||||
if (fn === "save") {
|
||||
this.indentLevel++;
|
||||
}
|
||||
|
||||
if (decArgs instanceof HTMLElement) {
|
||||
line.appendChild(decArgs);
|
||||
} else {
|
||||
|
|
|
@ -1707,6 +1707,7 @@ html[dir="rtl"] #documentPropertiesOverlay .row > * {
|
|||
}
|
||||
#PDFBug table {
|
||||
font-size: 10px;
|
||||
white-space: pre;
|
||||
}
|
||||
#PDFBug table.showText {
|
||||
border-collapse: collapse;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue