v1.4.6-patch2

This commit is contained in:
csh 2023-09-20 09:14:36 +08:00
parent f3094c148c
commit 493691b930
3 changed files with 6 additions and 6 deletions

View File

@ -13944,7 +13944,7 @@ Type TDocumentBody = Class(DocObject)
End;
End;
if bHeadList then Begin //统计大纲显示(目录)
styleId := p.Format.Value('StyleId');
styleId := p.Format.Value('StyleId', 1);
if styleId <> '' then Begin
obj := docx.StyleObject().GetStyleById(styleId);
if ifObj(obj) then Begin

View File

@ -154,7 +154,7 @@ public
return 1;
End
Function Value(name);
Function Value(name, nottransferable);
Begin
if not ifObj(RootObj) then return nil;
if NodeUri <> '' then
@ -169,7 +169,7 @@ public
if istable(r) then
begin
value := node.GetAttribute(r[1]);
return trystrtofloat(value, r) ? r : value;
return nottransferable ? value : trystrtofloat(value, r) ? r : value;
end
children := GetChildren();
@ -186,7 +186,7 @@ public
key := r['attrName'] ? r['attrName'] : r['attrEx'] ? r['attrEx'] : 'val';
value := node.GetAttribute(key);
if r['nodeType'] = 'empty' and value = '' then return true;
return trystrtofloat(value, r) ? r : value;
return nottransferable ? value : trystrtofloat(value, r) ? r : value;
End;
return nil;
End;

View File

@ -29,7 +29,7 @@ Type docxDocument = Class
markStart := p.FirstChildElement('w:bookmarkStart');
if ifObj(markStart) then Begin
id := markStart.GetAttribute('w:id');
if ifstring(id) then Begin
if ifstring(id) and id <> '' then Begin
iVal := strtoint(id);
if bookmarkid_ <= iVal then
bookmarkid_ := iVal + 1;
@ -48,4 +48,4 @@ private
body_;
document_;
bookmarkid_;
End;
End;