v1.6.6-patch2

This commit is contained in:
csh 2024-03-15 10:22:51 +08:00
parent 92257c380f
commit e105a205be
1 changed files with 21 additions and 0 deletions

View File

@ -377,6 +377,27 @@ Type TSXml = Class
return TOfficeApi().CurCodePageToUtf8(str); return TOfficeApi().CurCodePageToUtf8(str);
End; End;
// 获取docx的类型
// 普通段落0
// 图片段落1
// 表格2
// 其他:-1
class Function GetDocxPartType(part);
Begin
if not ifObj(part) then return -1;
case part.name_ of
'w:p':
begin
if class(TSXml).GetNode(part.node_, 'w:r/w:drawing') then return 1;
return 0;
end
'w:tbl':
return 2;
else
return -1;
end;
End;
//字体属性 //字体属性
class Function ReadRprFormat(node); class Function ReadRprFormat(node);
Begin Begin