[Lazarus] SessionProperties limited size problem

Bogusław Brandys brandys at o2.pl
Wed Mar 5 17:17:56 CET 2008


Paulo Malheiros wrote:
> Hello Mattias,
> 
> I made a test Application in Linux - SVN 14419
> Added 23 TEdit to Form1 and its SessionProperties
> 
>    TForm1 = class(TForm)
>      Edit1: TEdit;
>      Edit10: TEdit;
>      Edit11: TEdit;
>      Edit12: TEdit;
>      Edit13: TEdit;
>      Edit14: TEdit;
>      Edit15: TEdit;
>      Edit16: TEdit;
>      Edit17: TEdit;
>      Edit18: TEdit;
>      Edit19: TEdit;
>      Edit2: TEdit;
>      Edit20: TEdit;
>      Edit21: TEdit;
>      Edit22: TEdit;
>      Edit23: TEdit;
>      Edit3: TEdit;
>      Edit4: TEdit;
>      Edit5: TEdit;
>      Edit6: TEdit;
>      Edit7: TEdit;
>      Edit8: TEdit;
>      Edit9: TEdit;
>      IniPropStorage: TIniPropStorage;
>      procedure FormCreate(Sender: TObject);
>    private
>      { private declarations }
>    public
>      { public declarations }
>    end;
> 
> All were saved correctly. Closing Lazarus and checking "unit1.lfm" I got
> 
>    SessionProperties =
> 'Edit1.Text;Edit10.Text;Edit11.Text;Edit12.Text;Edit13.Text;Edit14.Text;Edit15.Text;Edit16.Text;Edit17.Text;Edit18.Text;Edit19.Text;Edit2.Text;Edit20.Text;Edit3.Text;Edit4.Text;Edit5.Text;Edit6.Text;Edit7.Text;Edit8.Text;Edit9.Text;Edit21.Text;Edit22.Text;Edit23.Text'
> 
> After reopening Lazarus and opening SessionProperties Dialog one  
> property was missing.
> After saving and exiting Lazarus reopened "unit1.lfm" I got
> 
>    SessionProperties =
> ';Edit1.Text;Edit10.Text;Edit11.Text;Edit12.Text;Edit13.Text;Edit14.Text;Edit15.Text;Edit16.Text;Edit17.Text;Edit18.Text;Edit19.Text;Edit2.Text;Edit20.Text;Edit21.Text;Edit22.Text;Edit3.Text;Edit4.Text;Edit5.Text;Edit6.Text;Edit7.Text;Edit8.Text;Edit9.Text'
> 
> Edit23.Text is missing.
> 
> Finally, If I change TStringPropertyEditor.GetEditLimit in  
> PropEdits.pp, from 255 to a
> bigger value all works fine.
> 
> function TStringPropertyEditor.GetEditLimit: Integer;
> begin
>    if GetPropType^.Kind = tkString then
>      Result := GetTypeData(GetPropType)^.MaxLength else
>      //Result := 255;
>      Result := 1023;
> end;
> 
> Is it possible to make SessionProperties without limit?
> 
> Regards,
> Paulo
> 

I think you should fill a bugreport. Apparently additional property to 
set this limit is needed.

Regards
Boguslaw



More information about the Lazarus mailing list