v1.5.5
This commit is contained in:
parent
fcb2a8e7b3
commit
dc7d48c318
|
|
@ -1,4 +1,4 @@
|
|||
// Version 1.5.4
|
||||
// Version 1.5.5
|
||||
Function TOfficeObj(n);
|
||||
Begin
|
||||
case lowercase(n) of
|
||||
|
|
@ -13890,12 +13890,21 @@ Type TDocumentBody = Class(DocObject)
|
|||
if name = 'w:p' and not ifObj(pNode.FirstChildElement('w:sectPr')) then
|
||||
begin
|
||||
pStyle := class(TSXml).GetNode(pNode, "w:pPr/w:pStyle");
|
||||
level := nil;
|
||||
if pStyle then
|
||||
begin
|
||||
styleId := pStyle.GetAttribute('w:val');
|
||||
if styleId <> '' and (obj := docx.StyleObject().GetStyleById(styleId)) and ifObj(obj) then
|
||||
begin
|
||||
level := getHeadingLevel(docx, obj);
|
||||
end
|
||||
end
|
||||
else begin
|
||||
level := class(TSXml).GetNode(pNode, "w:pPr/w:outlineLvl");
|
||||
if ifObj(level) then level := level.GetAttribute("w:val");
|
||||
end
|
||||
if not ifnil(level) then
|
||||
begin
|
||||
iLevel := Class(TSXml).SafeStrToIntDef(level, -1);
|
||||
if iLevel+1 >= UpperHeadingLevel and iLevel+1 <= LowerHeadingLevel then Begin
|
||||
//统计数字项目编号
|
||||
|
|
@ -13928,7 +13937,6 @@ Type TDocumentBody = Class(DocObject)
|
|||
ind++;
|
||||
End;
|
||||
end
|
||||
end
|
||||
End
|
||||
else if false and ifarray(numIds) and name = 'w:tbl' then Begin
|
||||
tbl := TOfficeObj('TTable');
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
// Version 1.5.4
|
||||
// Version 1.5.5
|
||||
Type TSDocxFile = Class
|
||||
///Version: V1.0 2022-09-20
|
||||
///适用于 Microsoft Word docx格式文件
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
// Version 1.5.4
|
||||
// Version 1.5.5
|
||||
Type TSXlsxFile = Class
|
||||
///Version: V1.0 2022-08-08
|
||||
///适用于 Microsoft Excel? 2007 及以上版本创建的电子表格文档。支持 XLSX / XLSM / XLTM / XLTX 等多种文档格式。
|
||||
|
|
@ -352,10 +352,9 @@ Type TSXlsxFile = Class
|
|||
for i:=0 to length(data)-1 do Begin
|
||||
for j:=0 to length(data[i])-1 do Begin
|
||||
[err, cell] := CoordinatesToCellName(colNum + j, rowNum + i);
|
||||
SetCellValue(sheet, cell, data[i][j]);
|
||||
ret := SetCellValue(sheet, cell, data[i][j]);
|
||||
if not ret then return array(1, "error")
|
||||
End;
|
||||
if err then
|
||||
return array(err, info);
|
||||
End;
|
||||
return array(0, "OK");
|
||||
End;
|
||||
|
|
|
|||
|
|
@ -284,7 +284,7 @@ Type TTableContent = class
|
|||
if ifObj(node) then
|
||||
return node.GetAttribute('w:name');
|
||||
bookMarkID := docx_.Document().GetBookMarkID();
|
||||
return p.AddBookMark();
|
||||
return p.AddBookMark(bookMarkID);
|
||||
End;
|
||||
|
||||
Function _CheckNodes(name);
|
||||
|
|
|
|||
|
|
@ -135,6 +135,7 @@ Type xlsxWorkBook = Class
|
|||
end
|
||||
ret := o.SetCellValue(axis, val, opt);
|
||||
end
|
||||
return ret;
|
||||
End;
|
||||
|
||||
Function GetCellRichText(sheet, axis);
|
||||
|
|
|
|||
Loading…
Reference in New Issue