diff options
author | Erich Eckner <git@eckner.net> | 2015-07-24 13:24:16 +0200 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2015-07-24 13:24:16 +0200 |
commit | 891ce27e2d7bf84a815d7019686bf7524b5deaf6 (patch) | |
tree | 9ae43619af2c5d450ef30fb218a747ec35980a58 /typenunit.pas | |
parent | 84ab8d37738f2e91f5084581dd728edd6e726190 (diff) | |
download | epost-891ce27e2d7bf84a815d7019686bf7524b5deaf6.tar.xz |
Umstrukturierung von tKnownValueArray zu tKnownValues
Diffstat (limited to 'typenunit.pas')
-rw-r--r-- | typenunit.pas | 32 |
1 files changed, 11 insertions, 21 deletions
diff --git a/typenunit.pas b/typenunit.pas index 6e7dab0..a600498 100644 --- a/typenunit.pas +++ b/typenunit.pas @@ -198,7 +198,7 @@ type maxW,minW,np,beta: extended; tsiz,xsteps,tsiz_,xsteps_: longint; transformationen: tTransformationen; - knownValues: tKnownValueArray; + knownValues: tKnownValues; constructor create; destructor destroy; override; function xstart: extended; @@ -867,13 +867,12 @@ begin xsteps:=0; tsiz_:=0; xsteps_:=0; - fillchar(knownValues,sizeof(knownValues),#0); - setlength(knownValues,0); + knownValues:=tKnownValues.create; end; destructor tExtraInfos.destroy; begin - setlength(knownValues,0); + knownValues.free; transformationen.free; inherited destroy; end; @@ -900,23 +899,14 @@ end; procedure tExtraInfos.refreshKnownValues; begin - setlength(knownValues,8); - knownValues[0].name:='np'; - knownValues[0].value:=np; - knownValues[1].name:='maxw'; - knownValues[1].value:=maxW; - knownValues[2].name:='minw'; - knownValues[2].value:=minW; - knownValues[3].name:='beta'; - knownValues[3].value:=beta; - knownValues[4].name:='xstart'; - knownValues[4].value:=xstart; - knownValues[5].name:='xstop'; - knownValues[5].value:=xstop; - knownValues[6].name:='tstart'; - knownValues[6].value:=tstart; - knownValues[7].name:='tstop'; - knownValues[7].value:=tstop; + knownValues.add(knownValue('np',np)); + knownValues.add(knownValue('maxw',maxW)); + knownValues.add(knownValue('minw',minW)); + knownValues.add(knownValue('beta',beta)); + knownValues.add(knownValue('xstart',xstart)); + knownValues.add(knownValue('xstop',xstop)); + knownValues.add(knownValue('tstart',tstart)); + knownValues.add(knownValue('tstop',tstop)); end; // tFontRenderer *************************************************************** |