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

Поправила баг когда после удаления в контенте оставался пустой Run со шрифтом...

Поправила баг когда после удаления в контенте оставался пустой Run со шрифтом Times New Roman, поэтому плейсхолдер отрисовывался не в Cambria Math

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@59803 954022d7-b5bf-4e40-9824-e11837661b57
parent 7d0bb325
......@@ -3504,7 +3504,8 @@ ParaRun.prototype.Draw_Elements = function(PDSE)
case para_Math_Text:
case para_Math_Placeholder:
{
var bChangeFont = Item.Is_SpecilalOperator() && !this.IsNormalText() && Font.FontFamily.Name !== "Cambria Math",
var bChangeFont = (Item.Is_SpecilalOperator() || this.IsPlaceholder()) && !this.IsNormalText() && Font.FontFamily.Name !== "Cambria Math",
FFont = {};
// опред набор символов, если Font не Cambria Math, рисуется все равно Font Cambria Math
......@@ -3935,6 +3936,7 @@ ParaRun.prototype.Set_ParaContentPos = function(ContentPos, Depth)
this.State.ContentPos = Pos;
TEST_MATH_RUN = this;
};
ParaRun.prototype.Get_PosByElement = function(Class, ContentPos, Depth, UseRange, Range, Line)
......@@ -7909,7 +7911,7 @@ ParaRun.prototype.Math_Recalculate = function(oMeasure, RPI, WidthPoints)
for (var i = 0 ; i < Lng; i++)
{
var bChangeFont = this.Content[i].Is_SpecilalOperator() && Font.FontFamily.Name !== "Cambria Math";
var bChangeFont = (this.Content[i].Is_SpecilalOperator() || this.IsPlaceholder()) && Font.FontFamily.Name !== "Cambria Math";
if(bChangeFont)
{
......@@ -8167,7 +8169,43 @@ function CParaRunStartState(Run)
}
}
var TEST_MATH_RUN = null;
function TEST_SYMBOLS()
{
//var Arr = [0x2398, 0x23CF, 0x23DC, 0x23E0, 0x2460, 0x2473, 0x24EA, 0x24F4, 0x24FF, 0x2500];
var Arr = [0x2776, 0x277F, 0x27D0, 0x27EB, 0x27F0, 0x27FF, 0x2900, 0x2AFF];
for(var k = 0; k < Arr.length; k += 2)
{
for(var i = Arr[k]; i <= Arr[k+1]; i++ )
{
AddItemToRun(TEST_MATH_RUN, i);
}
}
/*for(var i = 0x239B; i <= 0x23E0; i++)
{
AddItemToRun(Run, i);
}
//0x2C77
AddItemToRun(Run, 0x2E17);
for(var i = 0x3014; i <= 0x3017; i++)
{
AddItemToRun(Run, i);
}
for(var i = 0xFB00; i <= 0xFB04; i++)
{
AddItemToRun(Run, i);
}
AddItemToRun(Run, 0xFE00);*/
}
function AddItemToRun(Run, code)
{
......
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