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
43ecf8c1
Commit
43ecf8c1
authored
Mar 01, 2017
by
GoshaZotov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
+ for columns width
parent
9be7cd5d
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
6 deletions
+15
-6
cell/view/WorksheetView.js
cell/view/WorksheetView.js
+15
-6
No files found.
cell/view/WorksheetView.js
View file @
43ecf8c1
...
...
@@ -9550,6 +9550,7 @@
return
dxf
;
};
var
colsWidth
=
{};
var
putInsertedCellIntoRange
=
function
(
nRow
,
nCol
,
pasteRow
,
pasteCol
,
rowDiff
,
colDiff
,
range
,
newVal
)
{
var
pastedRangeProps
=
{};
...
...
@@ -9610,7 +9611,11 @@
}
pastedRangeProps
.
tableDxf
=
getTableDxf
(
pasteRow
,
pasteCol
,
newVal
);
pastedRangeProps
.
width
=
val
.
_getCol
(
pasteCol
);
if
(
undefined
===
colsWidth
[
nCol
])
{
colsWidth
[
nCol
]
=
val
.
_getCol
(
pasteCol
);
}
pastedRangeProps
.
colsWidth
=
colsWidth
;
//apply props by cell
var
formulaProps
=
{
firstRange
:
firstRange
,
arrFormula
:
arrFormula
,
tablesMap
:
tablesMap
,
newVal
:
newVal
,
isOneMerge
:
isOneMerge
,
val
:
val
};
...
...
@@ -9760,12 +9765,16 @@
//column width
if
(
specialPasteProps
.
width
&&
rangeStyle
.
width
)
var
col
=
range
.
bbox
.
c1
;
if
(
specialPasteProps
.
width
&&
rangeStyle
.
colsWidth
[
col
])
{
var
widthProp
=
rangeStyle
.
width
;
t
.
model
.
setColWidth
(
widthProp
.
width
,
range
.
bbox
.
c1
,
range
.
bbox
.
c1
);
t
.
model
.
setColHidden
(
widthProp
.
hd
,
range
.
bbox
.
c1
,
range
.
bbox
.
c1
);
t
.
model
.
setColBestFit
(
widthProp
.
BestFit
,
widthProp
.
width
,
range
.
bbox
.
c1
,
range
.
bbox
.
c1
);
var
widthProp
=
rangeStyle
.
colsWidth
[
col
];
t
.
model
.
setColWidth
(
widthProp
.
width
,
col
,
col
);
t
.
model
.
setColHidden
(
widthProp
.
hd
,
col
,
col
);
t
.
model
.
setColBestFit
(
widthProp
.
BestFit
,
widthProp
.
width
,
col
,
col
);
rangeStyle
.
colsWidth
[
col
]
=
null
;
}
//offsetLast
...
...
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