SiComponents Home Page SiComponents Forums
Here you will be able to get help and share your experience
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Rescan on every open

 
Post new topic   Reply to topic    SiComponents Forums Forum Index -> TsiLang Components Suite
View previous topic :: View next topic  
Author Message
LePrince



Joined: 25 Aug 2009
Posts: 9

PostPosted: Tue Nov 10, 2009 10:16 am    Post subject: Rescan on every open Reply with quote

Hi again, hope you are well!

Where is the procedure which re-scans the form every time it is opened? I want to skip this because it takes about 25 seconds which is more than an average user is willing to wait.

Thanks and best wishes,
Wolfgang
Back to top
View user's profile Send private message
isiticov
Site Admin


Joined: 21 Nov 2002
Posts: 2102

PostPosted: Thu Nov 12, 2009 8:47 am    Post subject: Reply with quote

Hello,

You can just add components and properties you don't need to be translated to excluded lists and this will reduce the time for scanning.
Back to top
View user's profile Send private message
LePrince



Joined: 25 Aug 2009
Posts: 9

PostPosted: Thu Nov 12, 2009 11:40 am    Post subject: Reply with quote

Thanks for the suggestion, Igor.

My situation is that at designtime i do not know what the form will look like and the translation editor is called at runtime. So i do not have the chance of excluding all properties i do not want. Some i know and some i don't.

But i guess there is little we can do about scanning and scanning-times anyway.

Except for one thing:
The function TsiLang.AddString always does a sort. I have nearly 7000 strings in the container and want to add 30 strings (at runtime). Every AddString sorts again and consumes a remarkable amount of time. Multiply with 30 and you will understand that a customer gets angry ... please try to get a solution for this - maybe you can add a flag which indicates whether the stringlist is sorted already. If so, then insert the string at the correct position. This way no sorting is necessary. Just a thought Wink

Thanks and best wishes,
Wolfgang
Back to top
View user's profile Send private message
Jean-Paul Brassard



Joined: 08 May 2008
Posts: 65

PostPosted: Fri Feb 26, 2010 2:39 am    Post subject: Re: Rescan on every open Reply with quote

LePrince wrote:
Hi again, hope you are well!

Where is the procedure which re-scans the form every time it is opened? I want to skip this because it takes about 25 seconds which is more than an average user is willing to wait.

Thanks and best wishes,
Wolfgang

Hi,

TsiLang uses Delphi classes to extract translation info, which is a quite slow process... To improve Form loading time, we wrote a dedicated class that directly read SIB files (as text) and extract strings. About 20x faster that Delphi. Cool
Back to top
View user's profile Send private message
LePrince



Joined: 25 Aug 2009
Posts: 9

PostPosted: Fri Feb 26, 2010 7:16 am    Post subject: Reply with quote

This sounds promising, would you be willing to share?
Best regards,
Wolfgang
Back to top
View user's profile Send private message
Jean-Paul Brassard



Joined: 08 May 2008
Posts: 65

PostPosted: Fri Feb 26, 2010 2:44 pm    Post subject: Reply with quote

LePrince wrote:
This sounds promising, would you be willing to share?
Best regards,
Wolfgang

Yes, we could share, but first I must tell that our code is dedicted to speed up loading Parent's strings (inheritance problem). We did not (yet) replace the TsiLang initialisation of the Child Form, even we also feel that this part could also be quite faster.

So it may not apply directly to your needs.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    SiComponents Forums Forum Index -> TsiLang Components Suite All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by p h p B B  © 2001, 2005 p h p B B  Group