Merge pull request #656 from ONLYOFFICE/fix/bugfix

Fix Bug 48258
This commit is contained in:
Julia Radzhabova 2021-01-18 13:32:15 +03:00 committed by GitHub
commit f0657548cc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 21 additions and 3 deletions

View file

@ -394,7 +394,13 @@ define([
if (this._state.LineRuleIdx !== null) {
this.numLineHeight.setDefaultUnit(this._arrLineRule[this._state.LineRuleIdx].defaultUnit);
this.numLineHeight.setStep(this._arrLineRule[this._state.LineRuleIdx].step);
this.numLineHeight && this.numLineHeight.setValue((this._state.LineHeight !== null) ? Common.Utils.Metric.fnRecalcFromMM(this._state.LineHeight) : '', true);
var val = '';
if ( this._state.LineRuleIdx == c_paragraphLinerule.LINERULE_AUTO ) {
val = this._state.LineHeight;
} else if (this._state.LineHeight !== null ) {
val = Common.Utils.Metric.fnRecalcFromMM(this._state.LineHeight);
}
this.numLineHeight && this.numLineHeight.setValue((val !== null) ? val : '', true);
}
var val = this._state.LineSpacingBefore;

View file

@ -246,7 +246,13 @@ define([
if (!rec) rec = this.cmbLineRule.store.at(0);
this.numLineHeight.setDefaultUnit(rec.get('defaultUnit'));
this.numLineHeight.setStep(rec.get('step'));
this.numLineHeight && this.numLineHeight.setValue((this._state.LineHeight !== null) ? Common.Utils.Metric.fnRecalcFromMM(this._state.LineHeight) : '', true);
var val = '';
if ( this._state.LineRule == c_paragraphLinerule.LINERULE_AUTO ) {
val = this._state.LineHeight;
} else if (this._state.LineHeight !== null ) {
val = Common.Utils.Metric.fnRecalcFromMM(this._state.LineHeight);
}
this.numLineHeight && this.numLineHeight.setValue((val !== null) ? val : '', true);
}
}
},

View file

@ -249,7 +249,13 @@ define([
if (!rec) rec = this.cmbLineRule.store.at(0);
this.numLineHeight.setDefaultUnit(rec.get('defaultUnit'));
this.numLineHeight.setStep(rec.get('step'));
this.numLineHeight && this.numLineHeight.setValue((this._state.LineHeight !== null) ? Common.Utils.Metric.fnRecalcFromMM(this._state.LineHeight) : '', true);
var val = '';
if ( this._state.LineRule == c_paragraphLinerule.LINERULE_AUTO ) {
val = this._state.LineHeight;
} else if (this._state.LineHeight !== null ) {
val = Common.Utils.Metric.fnRecalcFromMM(this._state.LineHeight);
}
this.numLineHeight && this.numLineHeight.setValue((val !== null) ? val : '', true);
}
}
},