1. self.替换成{self.}

2. 修复table表格绘画失败问题
This commit is contained in:
csh
2024-07-10 16:17:44 +08:00
parent 615f4a5b39
commit d3f9431b26
15 changed files with 276 additions and 269 deletions
-65
View File
@@ -1,65 +0,0 @@
type TSPdfSingletonKit = class
public
function Create();
class function Release(components: Components);
class function GetComponent(components: Components; type: string);
public
hash_: array of tslobj;
private
static singleton_: Singleton;
end;
function TSPdfSingletonKit.Create();
begin
hash_ := array();
end;
class function TSPdfSingletonKit.Release(components: Components);
begin
singleton_.hash_[components] := nil;
end;
class function TSPdfSingletonKit.GetComponent(components: Components; type: string);
begin
if not ifObj(singleton_) then singleton_ := new TSPdfSingletonKit();
if ifnil(singleton_.hash_[components]) then singleton_.hash_[components] := array();
if ifObj(singleton_.hash_[components][type]) then return singleton_.hash_[components][type];
case type of
"styles":
begin
styles := components.Styles;
styles.Deserialize();
singleton_.hash_[components][type] := styles;
return styles;
end
"styles_adapter":
begin
styles := class(TSPdfSingletonKit).GetComponent(components, "styles");
styles_adapter := new StylesAdapter(styles);
singleton_.hash_[components][type] := styles_adapter;
return styles_adapter;
end
"numbering_ware":
begin
numbering := components.Numbering;
numbering_ware := nil;
if ifObj(numbering) then
begin
numbering.Deserialize();
numbering_ware := new TSNumberingWare(numbering);
end
singleton_.hash_[components][type] := numbering_ware;
return numbering_ware;
end
"document_rels_adapter":
begin
document_rels := components.DocumentRels;
document_rels.Deserialize();
rels_adapter := new RelationShipsAdapter(document_rels);
singleton_.hash_[components][type] := rels_adapter;
return rels_adapter;
end
end;
end;
+2 -2
View File
@@ -1,8 +1,8 @@
type TSPoint = class
function Create();
begin
self.X := 0;
self.Y := 0;
{self.}X := 0;
{self.}Y := 0;
end
X: real;
Y: real;