зеркало из https://github.com/mozilla/ace.git
Include padding when calculating the printMaring
This commit is contained in:
Родитель
725820e05d
Коммит
172b9e9ca8
|
@ -116,8 +116,8 @@ var VirtualRenderer = function(container, theme) {
|
|||
this.$loop = new RenderLoop(this.$renderChanges.bind(this));
|
||||
this.$loop.schedule(this.CHANGE_FULL);
|
||||
|
||||
this.$updatePrintMargin();
|
||||
this.setPadding(4);
|
||||
this.$updatePrintMargin();
|
||||
};
|
||||
|
||||
(function() {
|
||||
|
@ -280,7 +280,7 @@ var VirtualRenderer = function(container, theme) {
|
|||
}
|
||||
|
||||
var style = this.$printMarginEl.style;
|
||||
style.left = (this.characterWidth * this.$printMarginColumn) + "px";
|
||||
style.left = ((this.characterWidth * this.$printMarginColumn) + this.$padding * 2) + "px";
|
||||
style.visibility = this.$showPrintMargin ? "visible" : "hidden";
|
||||
};
|
||||
|
||||
|
@ -320,6 +320,7 @@ var VirtualRenderer = function(container, theme) {
|
|||
this.$padding = padding;
|
||||
this.content.style.padding = "0 " + padding + "px";
|
||||
this.$loop.schedule(this.CHANGE_FULL);
|
||||
this.$updatePrintMargin();
|
||||
};
|
||||
|
||||
this.onScroll = function(e) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче