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
1c6663ac
Commit
1c6663ac
authored
May 27, 2016
by
Sergey Luzyanin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Поправил баги с отображением автофигур в таблицах, полученных из xls
parent
74ccec69
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
48 additions
and
9 deletions
+48
-9
common/Drawings/Format/Format.js
common/Drawings/Format/Format.js
+2
-0
common/Drawings/Format/Shape.js
common/Drawings/Format/Shape.js
+23
-5
common/Drawings/States.js
common/Drawings/States.js
+20
-3
common/Drawings/TrackObjects/NewShapeTracks.js
common/Drawings/TrackObjects/NewShapeTracks.js
+3
-0
slide/Editor/Format/ShapePrototype.js
slide/Editor/Format/ShapePrototype.js
+0
-1
No files found.
common/Drawings/Format/Format.js
View file @
1c6663ac
...
...
@@ -12130,6 +12130,8 @@ function CorrectUniColor(asc_color, unicolor, flag)
window
[
'
AscFormat
'
].
_global_layout_summs_array
=
_global_layout_summs_array
;
window
[
'
AscFormat
'
].
nOTOwerflow
=
nOTOwerflow
;
window
[
'
AscFormat
'
].
nOTClip
=
nOTClip
;
window
[
'
AscFormat
'
].
nOTEllipsis
=
nOTEllipsis
;
window
[
'
AscFormat
'
].
BULLET_TYPE_BULLET_NONE
=
BULLET_TYPE_BULLET_NONE
;
window
[
'
AscFormat
'
].
BULLET_TYPE_BULLET_CHAR
=
BULLET_TYPE_BULLET_CHAR
;
...
...
common/Drawings/Format/Shape.js
View file @
1c6663ac
...
...
@@ -752,7 +752,12 @@ CShape.prototype.createTextBody = function () {
var
tx_body
=
new
AscFormat
.
CTextBody
();
tx_body
.
setParent
(
this
);
tx_body
.
setContent
(
new
CDocumentContent
(
tx_body
,
this
.
getDrawingDocument
(),
0
,
0
,
0
,
20000
,
false
,
false
,
true
));
tx_body
.
setBodyPr
(
new
AscFormat
.
CBodyPr
());
var
oBodyPr
=
new
AscFormat
.
CBodyPr
();
if
(
this
.
worksheet
){
oBodyPr
.
vertOverflow
=
AscFormat
.
nOTClip
;
oBodyPr
.
horzOverflow
=
AscFormat
.
nOTClip
;
}
tx_body
.
setBodyPr
(
oBodyPr
);
tx_body
.
content
.
Content
[
0
].
Set_DocumentIndex
(
0
);
this
.
setTxBody
(
tx_body
);
};
...
...
@@ -1779,7 +1784,7 @@ CShape.prototype.checkTransformTextMatrix = function (oMatrix, oContent, oBodyPr
_vertical_shift
=
0
;
}
else
{
if
(
!
(
this
.
bWordShape
||
this
.
worksheet
)
||
_content_height
<
_text_rect_height
)
{
if
(
(
!
this
.
bWordShape
&&
oBodyPr
.
vertOverflow
===
AscFormat
.
nOTOwerflow
)
||
_content_height
<
_text_rect_height
)
{
switch
(
oBodyPr
.
anchor
)
{
case
0
:
//b
{
// (Text Anchor Enum ( Bottom ))
...
...
@@ -1835,7 +1840,7 @@ CShape.prototype.checkTransformTextMatrix = function (oMatrix, oContent, oBodyPr
_vertical_shift
=
0
;
}
else
{
if
(
!
(
this
.
bWordShape
||
this
.
worksheet
)
||
_content_height
<
_text_rect_width
)
{
if
(
(
!
this
.
bWordShape
&&
oBodyPr
.
vertOverflow
===
AscFormat
.
nOTOwerflow
)
||
_content_height
<
_text_rect_width
)
{
switch
(
oBodyPr
.
anchor
)
{
case
0
:
//b
{
// (Text Anchor Enum ( Bottom ))
...
...
@@ -3855,6 +3860,18 @@ CShape.prototype.clipTextRect = function(graphics)
{
var
clip_rect
=
this
.
clipRect
;
var
oBodyPr
=
this
.
getBodyPr
();
if
(
!
this
.
bWordShape
)
{
if
(
oBodyPr
.
vertOverflow
===
AscFormat
.
nOTOwerflow
&&
oBodyPr
.
horzOverflow
===
AscFormat
.
nOTOwerflow
)
{
return
;
}
clip_rect
=
{
x
:
this
.
clipRect
.
x
,
y
:
this
.
clipRect
.
y
,
w
:
this
.
clipRect
.
w
,
h
:
this
.
clipRect
.
h
};
if
(
oBodyPr
.
vertOverflow
===
AscFormat
.
nOTOwerflow
&&
AscFormat
.
isRealNumber
(
this
.
contentHeight
))
{
clip_rect
.
h
=
this
.
contentHeight
;
}
}
if
(
!
oBodyPr
||
!
oBodyPr
.
upright
)
{
graphics
.
transform3
(
this
.
transform
);
...
...
@@ -4036,9 +4053,10 @@ CShape.prototype.draw = function (graphics, transform, transformText, pageIndex)
transform_text
=
_transform_text
;
}
if
(
this
.
worksheet
&&
(
this
instanceof
CShape
)
&&
!
(
oController
&&
(
AscFormat
.
getTargetTextObject
(
oController
)
===
this
))
)
if
(
this
instanceof
CShape
)
{
this
.
clipTextRect
(
graphics
);
if
(
!
(
oController
&&
(
AscFormat
.
getTargetTextObject
(
oController
)
===
this
)))
this
.
clipTextRect
(
graphics
);
}
graphics
.
transform3
(
this
.
transformText
,
true
);
if
(
graphics
.
CheckUseFonts2
!==
undefined
)
...
...
common/Drawings/States.js
View file @
1c6663ac
...
...
@@ -161,10 +161,27 @@ StartAddNewShape.prototype =
function
checkEmptyPlaceholderContent
(
content
)
{
if
(
!
content
||
content
.
Parent
&&
content
.
Parent
.
parent
&&
(
content
.
Is_Empty
()
&&
content
.
Parent
.
parent
.
isPlaceholder
&&
content
.
Parent
.
parent
.
isPlaceholder
()
||
content
.
Parent
.
parent
.
txWarpStruct
||
content
.
Parent
.
parent
.
recalcInfo
&&
content
.
Parent
.
parent
.
recalcInfo
.
warpGeometry
||
content
.
Parent
.
parent
.
worksheet
)
)
if
(
!
content
){
return
content
;
}
if
(
content
.
Parent
&&
content
.
Parent
.
parent
){
if
(
content
.
Is_Empty
()
&&
content
.
Parent
.
parent
.
isPlaceholder
&&
content
.
Parent
.
parent
.
isPlaceholder
()){
return
content
;
}
if
(
content
.
Parent
.
parent
.
txWarpStruct
){
return
content
;
}
if
(
content
.
Parent
.
parent
.
recalcInfo
&&
content
.
Parent
.
parent
.
recalcInfo
.
warpGeometry
){
return
content
;
}
var
oBodyPr
;
if
(
content
.
Parent
.
parent
.
getBodyPr
){
oBodyPr
=
content
.
Parent
.
parent
.
getBodyPr
;
if
(
oBodyPr
.
vertOverflow
!==
AscFormat
.
nOTOwerflow
){
return
content
;
}
}
}
return
null
;
}
...
...
common/Drawings/TrackObjects/NewShapeTracks.js
View file @
1c6663ac
...
...
@@ -509,6 +509,9 @@ function NewShapeTrack(presetGeom, startX, startY, theme, master, layout, slide,
shape
.
txBody
.
setContent
(
content
);
var
body_pr
=
new
AscFormat
.
CBodyPr
();
body_pr
.
setDefault
();
if
(
drawingObjects
&&
!
drawingObjects
.
cSld
){
body_pr
.
vertOverflow
=
AscFormat
.
nOTClip
;
}
shape
.
txBody
.
setBodyPr
(
body_pr
);
}
}
...
...
slide/Editor/Format/ShapePrototype.js
View file @
1c6663ac
...
...
@@ -467,7 +467,6 @@ CShape.prototype.recalculate = function ()
if
(
this
.
recalcInfo
.
recalculateTransformText
&&
check_slide_placeholder
)
{
this
.
recalculateTransformText
();
this
.
recalcInfo
.
recalculateTransformText
=
false
;
this
.
clipRect
=
null
;
}
if
(
this
.
recalcInfo
.
recalculateBounds
)
{
...
...
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