Commit 2b9aec87 authored by Anna.Pavlova's avatar Anna.Pavlova Committed by Alexander.Trofimov

Правки свойства у класса CDelimiters : chr to Unicode

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@56898 954022d7-b5bf-4e40-9824-e11837661b57
parent f5ea8f2b
......@@ -7583,7 +7583,7 @@ CMathContent.prototype =
var oSSub0 = new CDegree(props);
this.CreateDegree(oSSub0, delimiterBase, "X", null, "n");
sChar = String.fromCharCode(8898);
var sChar = String.fromCharCode(8898);
this.AddText(delimiterBase, sChar);
props = {ctrPrp: new CTextPr(), type:DEGREE_SUBSCRIPT};
......
......@@ -2952,24 +2952,37 @@ COperator.prototype.getProps = function(props, defaultProps)
chr = props.chr,
type = props.type;
var code = props.chr;
this.defaultType = defaultProps.type;
var bDelimiter = this.type == OPER_DELIMITER || this.type == OPER_SEPARATOR,
bNotType = typeof(props.type) == "undefined" || props.type == null,
bStr = typeof(chr) === "string",
bEmptyStr = bStr && chr.length == 0,
bCode = typeof(chr) === "string" && chr.length > 0;
bNotType = typeof(props.type) == "undefined" || props.type == null,
bUnicodeChr = props.chr !== null && props.chr+0 == props.chr;
//bStr = typeof(chr) === "string",
//bEmptyStr = bStr && chr.length == 0,
//bCode = typeof(chr) === "string" && chr.length > 0;
//var code = bCode ? chr.charCodeAt(0) : null;
if(bDelimiter && bUnicodeChr == -1) // empty operator
{
type = OPERATOR_EMPTY;
}
else if(bNotType && !bUnicodeChr) // default operator
{
type = defaultProps.type;
}
var code = bCode ? chr.charCodeAt(0) : null;
var bDPrpDelim = bDelimiter && bNotType && !bStr,
/*var bDPrpDelim = bDelimiter && bNotType && !bStr,
bDPrpOther = !bDelimiter && bNotType && !bCode;
var bDefault = bDPrpDelim || bDPrpOther,
bEmpty = bDelimiter && bEmptyStr;
var bLoc = props.loc !== null && typeof(props.loc)!== "undefined";
var bDefaultLoc = defaultProps.loc !== null && typeof(defaultProps.loc)!== "undefined";
if(bDefault)
{
......@@ -2978,7 +2991,10 @@ COperator.prototype.getProps = function(props, defaultProps)
else if(bEmpty)
{
type = OPERATOR_EMPTY;
}
}*/
var bLoc = props.loc !== null && typeof(props.loc)!== "undefined";
var bDefaultLoc = defaultProps.loc !== null && typeof(defaultProps.loc)!== "undefined";
if(!bLoc && bDefaultLoc)
......@@ -3905,7 +3921,7 @@ CDelimiter.prototype.getBase = function(numb)
}
CDelimiter.prototype.getPropsForWrite = function()
{
var props =
/*var props =
{
grow: this.Pr.grow,
column: this.nCol,
......@@ -3915,7 +3931,9 @@ CDelimiter.prototype.getPropsForWrite = function()
sepChr: this.sepOper.getChr() // default: DELIMITER_LINE
};
return props;
return props;*/
return this.Pr;
}
CDelimiter.prototype.Save_Changes = function(Data, Writer)
{
......@@ -4227,9 +4245,6 @@ CGroupCharacter.prototype.Resize = function(Parent, ParaMath, oMeasure)
this.setCharacter(operProps, operDefaultPrp);
this.Pr.chrType = this.operator.typeOper;
this.Pr.chr = String.fromCharCode(this.operator.code);
this.RecalcInfo.bProps = false;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment