Commit 3c5fd75c authored by Sergey Luzyanin's avatar Sergey Luzyanin

add prstDash to asc_CStroke

parent 2ee972a9
...@@ -11611,6 +11611,7 @@ function CreateAscStroke(ln, _canChangeArrows) ...@@ -11611,6 +11611,7 @@ function CreateAscStroke(ln, _canChangeArrows)
break; break;
} }
} }
} }
...@@ -11650,7 +11651,12 @@ function CreateAscStroke(ln, _canChangeArrows) ...@@ -11650,7 +11651,12 @@ function CreateAscStroke(ln, _canChangeArrows)
{ {
ret.asc_putLineendstyle(LineEndType.None); ret.asc_putLineendstyle(LineEndType.None);
} }
if(AscFormat.isRealNumber(ln.prstDash)){
ret.prstDash = ln.prstDash;
}
else{
ret.prstDash = Asc.c_oDashType.solid;
}
if (true === _canChangeArrows) if (true === _canChangeArrows)
ret.canChangeArrows = true; ret.canChangeArrows = true;
...@@ -11739,7 +11745,12 @@ function CorrectUniStroke(asc_stroke, unistroke, flag) ...@@ -11739,7 +11745,12 @@ function CorrectUniStroke(asc_stroke, unistroke, flag)
ret.tailEnd.w = 2 - ((_end_size/3) >> 0); ret.tailEnd.w = 2 - ((_end_size/3) >> 0);
ret.tailEnd.len = 2 - (_end_size % 3); ret.tailEnd.len = 2 - (_end_size % 3);
} }
if(AscFormat.isRealNumber(asc_stroke.prstDash)){
ret.prstDash = asc_stroke.prstDash;
}
else{
ret.prstDash = Asc.c_oDashType.solid;
}
return ret; return ret;
} }
......
...@@ -2022,6 +2022,7 @@ ...@@ -2022,6 +2022,7 @@
this.type = null; this.type = null;
this.width = null; this.width = null;
this.color = null; this.color = null;
this.prstDash = null;
this.LineJoin = null; this.LineJoin = null;
this.LineCap = null; this.LineCap = null;
...@@ -2057,7 +2058,10 @@ ...@@ -2057,7 +2058,10 @@
asc_getLineendsize: function(){return this.LineEndSize;}, asc_getLineendsize: function(){return this.LineEndSize;},
asc_putLineendsize: function(v){this.LineEndSize = v;}, asc_putLineendsize: function(v){this.LineEndSize = v;},
asc_getCanChangeArrows: function(){return this.canChangeArrows;} asc_getCanChangeArrows: function(){return this.canChangeArrows;},
asc_putPrstDash: function(v){this.prstDash = v;},
asc_getPrstDash: function(){ return this.prstDash;}
}; };
// цвет. может быть трех типов: // цвет. может быть трех типов:
...@@ -2868,6 +2872,8 @@ ...@@ -2868,6 +2872,8 @@
prot["get_lineendsize"] = prot["asc_getLineendsize"] = prot.asc_getLineendsize; prot["get_lineendsize"] = prot["asc_getLineendsize"] = prot.asc_getLineendsize;
prot["put_lineendsize"] = prot["asc_putLineendsize"] = prot.asc_putLineendsize; prot["put_lineendsize"] = prot["asc_putLineendsize"] = prot.asc_putLineendsize;
prot["get_canChangeArrows"] = prot["asc_getCanChangeArrows"] = prot.asc_getCanChangeArrows; prot["get_canChangeArrows"] = prot["asc_getCanChangeArrows"] = prot.asc_getCanChangeArrows;
prot["put_prstDash"] = prot["asc_putPrstDash"] = prot.asc_putPrstDash;
prot["get_prstDash"] = prot["asc_getPrstDash"] = prot.asc_getPrstDash;
window["AscCommon"].CAscColorScheme = CAscColorScheme; window["AscCommon"].CAscColorScheme = CAscColorScheme;
prot = CAscColorScheme.prototype; prot = CAscColorScheme.prototype;
......
...@@ -812,6 +812,20 @@ var c_oAscPrintDefaultSettings = { ...@@ -812,6 +812,20 @@ var c_oAscPrintDefaultSettings = {
CustomMode : 3 CustomMode : 3
}; };
var c_oDashType = {
dash: 0,
dashDot: 1,
dot: 2,
lgDash: 3,
lgDashDot: 4,
lgDashDotDot: 5,
solid: 6,
sysDash: 7,
sysDashDot: 8,
sysDashDotDot: 9,
sysDot: 10
};
var c_oAscEncodings = [ var c_oAscEncodings = [
[ 0, 28596, "ISO-8859-6", "Arabic (ISO 8859-6)" ], [ 0, 28596, "ISO-8859-6", "Arabic (ISO 8859-6)" ],
[ 1, 720, "DOS-720", "Arabic (OEM 720)" ], [ 1, 720, "DOS-720", "Arabic (OEM 720)" ],
...@@ -1399,7 +1413,21 @@ window['Asc']['c_oAscMaxCellOrCommentLength'] = window['Asc'].c_oAscMaxCellOrCom ...@@ -1399,7 +1413,21 @@ window['Asc']['c_oAscMaxCellOrCommentLength'] = window['Asc'].c_oAscMaxCellOrCom
prot['DeleteRows'] = prot.DeleteRows; prot['DeleteRows'] = prot.DeleteRows;
prot['DeleteTable'] = prot.DeleteTable; prot['DeleteTable'] = prot.DeleteTable;
window['AscCommon'] = window['AscCommon'] || {}; window['Asc']['c_oDashType'] = window['Asc'].c_oDashType = c_oDashType;
prot = c_oDashType;
prot['dash'] = prot.dash;
prot['dashDot'] = prot.dashDot;
prot['dot'] = prot.dot;
prot['lgDash'] = prot.lgDash;
prot['lgDashDot'] = prot.lgDashDot;
prot['lgDashDotDot'] = prot.lgDashDotDot;
prot['solid'] = prot.solid;
prot['sysDash'] = prot.sysDash;
prot['sysDashDot'] = prot.sysDashDot;
prot['sysDashDotDot'] = prot.sysDashDotDot;
prot['sysDot'] = prot.sysDot;
window['AscCommon'] = window['AscCommon'] || {};
window["AscCommon"].g_cCharDelimiter = g_cCharDelimiter; window["AscCommon"].g_cCharDelimiter = g_cCharDelimiter;
window["AscCommon"].bDate1904 = false; window["AscCommon"].bDate1904 = false;
window["AscCommon"].c_oAscAdvancedOptionsAction = c_oAscAdvancedOptionsAction; window["AscCommon"].c_oAscAdvancedOptionsAction = c_oAscAdvancedOptionsAction;
......
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