Issue 166: Color goes away
o According to the poster, Hello, here is a patch to fix the problem. The problem was that in some places the author wrote "elem.style.className" while the correct property is "elem.className", thus when the screen was recreated (to fix some bug linked to print preview apparently), the property wasn't saved correctly. Changes applied.
This commit is contained in:
parent
1139b09b62
commit
b7dac10ec1
1 changed files with 2 additions and 2 deletions
|
@ -1106,7 +1106,7 @@ VT100.prototype.repairElements = function(console) {
|
||||||
for (var span = line.firstChild; span; span = span.nextSibling) {
|
for (var span = line.firstChild; span; span = span.nextSibling) {
|
||||||
var newSpan = document.createElement(span.tagName);
|
var newSpan = document.createElement(span.tagName);
|
||||||
newSpan.style.cssText = span.style.cssText;
|
newSpan.style.cssText = span.style.cssText;
|
||||||
newSpan.style.className = span.style.className;
|
newSpan.className = span.className;
|
||||||
this.setTextContent(newSpan, this.getTextContent(span));
|
this.setTextContent(newSpan, this.getTextContent(span));
|
||||||
newLine.appendChild(newSpan);
|
newLine.appendChild(newSpan);
|
||||||
}
|
}
|
||||||
|
@ -1517,7 +1517,7 @@ VT100.prototype.insertBlankLine = function(y, color, style) {
|
||||||
line = document.createElement('div');
|
line = document.createElement('div');
|
||||||
var span = document.createElement('span');
|
var span = document.createElement('span');
|
||||||
span.style.cssText = style;
|
span.style.cssText = style;
|
||||||
span.style.className = color;
|
span.className = color;
|
||||||
this.setTextContent(span, this.spaces(this.terminalWidth));
|
this.setTextContent(span, this.spaces(this.terminalWidth));
|
||||||
line.appendChild(span);
|
line.appendChild(span);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue