This commit is contained in:
csh
2025-10-29 15:47:51 +08:00
parent ca03e53285
commit a2c3905cd0
5 changed files with 4174 additions and 4126 deletions
+24 -7
View File
@@ -1,4 +1,4 @@
// Version 1.8.1 // Version 1.8.2
Function TOfficeObj(n); Function TOfficeObj(n);
Begin Begin
case lowercase(n) of case lowercase(n) of
@@ -11143,16 +11143,33 @@ Type TParagraph = Class(DocObject, TParagraphImpl)
Begin Begin
if ifObj(node_) then if ifObj(node_) then
begin begin
if ifObj(node_.FirstChildElement("w:r")) then return false;
sub_node := node_.FirstChildElement(); sub_node := node_.FirstChildElement();
if not ifObj(sub_node) then return true; if not ifObj(sub_node) then return true;
// 兼容wps
sub_node2 := sub_node.NextElement(); sub_node2 := sub_node.NextElement();
if sub_node.GetName() = 'w:bookmarkStart' and ifObj(sub_node2) and sub_node2.GetName() = 'w:bookmarkEnd' then
return true; sub_node_name := sub_node.GetName();
if sub_node_name = "w:r" then
begin
r_sub_node := sub_node.FirstChildElement();
if not ifObj(r_sub_node) then return true;
while ifObj(r_sub_node) do
begin
sub_node2_name := r_sub_node.GetName();
if sub_node2_name = 'w:t' and trim(r_sub_node.GetText()) <> '' then return fasle;
else if sub_node2_name in array('mc:AlternateContent', 'w:drawing', 'w:pict', 'w:object') then return false;
r_sub_node := r_sub_node.NextElement();
end
end
// 兼容word // 兼容word
if sub_node.GetName() = 'w:pPr' and not ifObj(sub_node2) then else if sub_node_name = 'w:pPr' and not ifObj(sub_node2) then
begin
return true; return true;
end
// 兼容wps
else if sub_node_name = 'w:bookmarkStart' and ifObj(sub_node2) and sub_node2.GetName() = 'w:bookmarkEnd' then
begin
return true;
end
end end
return false; return false;
End; End;
@@ -14144,7 +14161,7 @@ Type TDocumentBody = Class(DocObject)
r[ind]['numId'] := arr[ii]['numId']; r[ind]['numId'] := arr[ii]['numId'];
r[ind]['ilvl'] := arr[ii]['ilvl']; r[ind]['ilvl'] := arr[ii]['ilvl'];
r[ind]['numArr'] := arr[ii]['numArr']; r[ind]['numArr'] := arr[ii]['numArr'];
ind++ ind++;
end end
End; End;
End; End;
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
+781 -767
View File
File diff suppressed because it is too large Load Diff