Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
sdkjs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boris Kocherov
sdkjs
Commits
583fad0c
Commit
583fad0c
authored
8 years ago
by
Sergey Luzyanin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fill gapes in sparklines
parent
5d2b9334
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
36 additions
and
2 deletions
+36
-2
common/Charts/DrawingObjects.js
common/Charts/DrawingObjects.js
+36
-2
No files found.
common/Charts/DrawingObjects.js
View file @
583fad0c
...
...
@@ -764,6 +764,7 @@ CSparklineView.prototype.initFromSparkline = function(oSparkline, oSparklineGrou
new_line
.
setFill
(
AscFormat
.
CreateNoFillUniFill
());
chart_space
.
spPr
.
setLn
(
new_line
);
chart_space
.
spPr
.
setFill
(
AscFormat
.
CreateNoFillUniFill
());
var
dLineWidthSpaces
=
500
;
if
(
!
chart_space
.
chart
.
plotArea
.
spPr
)
{
chart_space
.
chart
.
plotArea
.
setSpPr
(
new
AscFormat
.
CSpPr
());
...
...
@@ -821,15 +822,34 @@ CSparklineView.prototype.initFromSparkline = function(oSparkline, oSparklineGrou
{
if
(
oSeries
.
dPt
[
t
].
spPr
)
{
if
(
oExcelColor
){
oSeries
.
dPt
[
t
].
spPr
.
Fill
=
CreateUniFillFromExcelColor
(
oExcelColor
);
oSeries
.
dPt
[
t
].
spPr
.
ln
=
new
AscFormat
.
CLn
();
oSeries
.
dPt
[
t
].
spPr
.
ln
.
Fill
=
oSeries
.
dPt
[
t
].
spPr
.
Fill
.
createDuplicate
();
oSeries
.
dPt
[
t
].
spPr
.
ln
.
w
=
dLineWidthSpaces
;
}
else
{
oSeries
.
dPt
[
t
].
spPr
.
Fill
=
AscFormat
.
CreateNoFillUniFill
();
oSeries
.
dPt
[
t
].
spPr
.
ln
=
AscFormat
.
CreateNoFillLine
();
}
}
return
;
}
}
var
oDPt
=
new
AscFormat
.
CDPt
();
oDPt
.
idx
=
nIdx
;
oDPt
.
spPr
=
new
AscFormat
.
CSpPr
();
if
(
oExcelColor
)
{
oDPt
.
spPr
.
Fill
=
CreateUniFillFromExcelColor
(
oExcelColor
);
oDPt
.
spPr
.
ln
=
new
AscFormat
.
CLn
();
oDPt
.
spPr
.
ln
.
Fill
=
oDPt
.
spPr
.
Fill
.
createDuplicate
();
oDPt
.
spPr
.
ln
.
w
=
dLineWidthSpaces
;
}
else
{
oDPt
.
spPr
.
Fill
=
AscFormat
.
CreateNoFillUniFill
();
oDPt
.
spPr
.
ln
=
AscFormat
.
CreateNoFillLine
();
}
oSeries
.
addDPt
(
oDPt
);
}
}
...
...
@@ -839,6 +859,17 @@ CSparklineView.prototype.initFromSparkline = function(oSparkline, oSparklineGrou
{
if
(
fCallbackSeries
)
{
if
(
oSparklineGroup
.
type
!==
Asc
.
c_oAscSparklineType
.
Line
){
for
(
i
=
0
;
i
<
aSeriesPoints
.
length
;
++
i
)
{
if
(
AscFormat
.
fApproxEqual
(
aSeriesPoints
[
i
].
val
,
0
))
{
fCallbackSeries
(
oSerie
,
aSeriesPoints
[
i
].
idx
,
null
);
}
}
}
if
(
oSparklineGroup
.
negative
&&
oSparklineGroup
.
colorNegative
)
{
for
(
i
=
0
;
i
<
aSeriesPoints
.
length
;
++
i
)
...
...
@@ -966,6 +997,9 @@ CSparklineView.prototype.initFromSparkline = function(oSparkline, oSparklineGrou
else
{
oSerie
.
spPr
.
setFill
(
oUnifill
);
oSerie
.
spPr
.
ln
=
new
AscFormat
.
CLn
();
oSerie
.
spPr
.
ln
.
Fill
=
oSerie
.
spPr
.
Fill
.
createDuplicate
();
oSerie
.
spPr
.
ln
.
w
=
dLineWidthSpaces
;
}
}
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment