75 lines
1.8 KiB
Plaintext
75 lines
1.8 KiB
Plaintext
type Miter = class(OpenXmlElement)
|
|
public
|
|
function Create();overload;
|
|
function Create(_node: XmlNode);overload;
|
|
function Create(_parent: tslobj; _prefix: string; _local_name: string);overload;
|
|
function Init();override;
|
|
function Copy(_obj: Miter);override;
|
|
|
|
public
|
|
|
|
// attributes property
|
|
property Lim read ReadXmlAttrLim write WriteXmlAttrLim;
|
|
function ReadXmlAttrLim();
|
|
function WriteXmlAttrLim(_value);
|
|
|
|
public
|
|
// Attributes
|
|
XmlAttrLim: OpenXmlAttribute;
|
|
|
|
|
|
end;
|
|
|
|
function Miter.Create();overload;
|
|
begin
|
|
{self.}Create(nil, "a", "miter");
|
|
end;
|
|
|
|
function Miter.Create(_node: XmlNode);overload;
|
|
begin
|
|
class(OpenXmlElement).Create(_node: XmlNode);
|
|
end;
|
|
|
|
function Miter.Create(_parent: tslobj; _prefix: string; _local_name: string);overload;
|
|
begin
|
|
setsysparam(pn_calcctrlword(), getsysparam(pn_calcctrlword()) .| 0x200);
|
|
class(OpenXmlElement).Create(_parent, _prefix, _local_name);
|
|
end;
|
|
|
|
function Miter.Init();override;
|
|
begin
|
|
pre := {self.}Prefix ? {self.}Prefix + ":" : "";
|
|
attributes_ := array();
|
|
attributes_pf_ := array(
|
|
"lim": makeweakref(thisFunction(WriteXmlAttrLim)),
|
|
);
|
|
sorted_child_ := array(
|
|
);
|
|
container_ := new TSOfficeContainer(sorted_child_);
|
|
end;
|
|
|
|
function Miter.Copy(_obj: Miter);override;
|
|
begin
|
|
tslassigning_backup := tslassigning;
|
|
tslassigning := 1;
|
|
class(OpenXmlElement).Copy(_obj);
|
|
if not ifnil(_obj.Lim) then
|
|
{self.}Lim := _obj.Lim;
|
|
tslassigning := tslassigning_backup;
|
|
end;
|
|
|
|
function Miter.ReadXmlAttrLim();
|
|
begin
|
|
return {self.}XmlAttrLim.Value;
|
|
end;
|
|
|
|
function Miter.WriteXmlAttrLim(_value);
|
|
begin
|
|
if ifnil({self.}XmlAttrLim) then
|
|
begin
|
|
{self.}XmlAttrLim := new OpenXmlAttribute("", "lim", nil);
|
|
attributes_[length(attributes_)] := {self.}XmlAttrLim;
|
|
end
|
|
{self.}XmlAttrLim.Value := _value;
|
|
end;
|