Improve heuristics for adding function-apply following operators. Issue #1312.
This commit is contained in:
parent
3cdcd73b01
commit
458cd7a760
|
@ -343,10 +343,12 @@
|
||||||
type: "fn",
|
type: "fn",
|
||||||
checkItem: function (item) {
|
checkItem: function (item) {
|
||||||
if (this.data[0]) {
|
if (this.data[0]) {
|
||||||
|
if (item.type !== "fn" && item.type !== "left") {
|
||||||
if (item.type !== "mml" || !item.data[0]) {return [this.data[0],item]}
|
if (item.type !== "mml" || !item.data[0]) {return [this.data[0],item]}
|
||||||
if (item.data[0].isa(MML.mspace)) {return [this.data[0],item]}
|
if (item.data[0].isa(MML.mspace)) {return [this.data[0],item]}
|
||||||
var mml = item.data[0]; if (mml.isEmbellished()) {mml = mml.CoreMO()}
|
var mml = item.data[0]; if (mml.isEmbellished()) {mml = mml.CoreMO()}
|
||||||
if ([0,0,1,1,0,1,1,0,0,0][mml.Get("texClass")]) {return [this.data[0],item]}
|
if ([0,0,1,1,0,1,1,0,0,0][mml.Get("texClass")]) {return [this.data[0],item]}
|
||||||
|
}
|
||||||
return [this.data[0],MML.mo(MML.entity("#x2061")).With({texClass:MML.TEXCLASS.NONE}),item];
|
return [this.data[0],MML.mo(MML.entity("#x2061")).With({texClass:MML.TEXCLASS.NONE}),item];
|
||||||
}
|
}
|
||||||
return this.SUPER(arguments).checkItem.apply(this,arguments);
|
return this.SUPER(arguments).checkItem.apply(this,arguments);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user