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 

Translation in runtime

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



Joined: 17 Aug 2004
Posts: 11

PostPosted: Mon Mar 21, 2005 8:34 am    Post subject: Translation in runtime Reply with quote

Hi,

I have modular application system with one dispatcher and one container (TsiLangRT) on whole application. On each form I have TsiLangLinked which is connected to dispatcher and container. Using procedure TransEditorDlg I created posibility of editing translation of each form in runtime. That means in runtime user (translating person) pressing ShortCut keys receive translator dialog (from TransEditorDlg) with translation of current form and he is able to translate what is inside the SIL file regarding current form - connection over dispatcher-storage file.

But, there is a problem that in if the form is changed by developer, some components (labels,...) could not be in SIL file (if developer forget to update the SIL file). I would like to put this responseblity to translating person. So I would like to combinate information from the form and SIL file.
My question is: How to extract all properties from form and then translate all of them with content from SIL file (something like merge)? And the best using TransEditorDlg Smile.

Any tips, propositions...

Thanks
KrisD
Back to top
View user's profile Send private message
isiticov
Site Admin


Joined: 21 Nov 2002
Posts: 2103

PostPosted: Mon Mar 21, 2005 2:48 pm    Post subject: Reply with quote

In case your newer components have no trnaslations defined then you can do the following:
1. Load all data from SIL file using LoadAllFromFile()
2. Call BuildList() method. This will add existing components (not defined in SIL) to the list and remove obsolete components from list.
3. Call translations editor dialog for editing.

Hope this helps.
Back to top
View user's profile Send private message
kdeberni



Joined: 17 Aug 2004
Posts: 11

PostPosted: Tue Mar 22, 2005 6:41 am    Post subject: Reply with quote

Hi,

Thanks a lot. It works and it is great. Smile

I have just one more question. What is the easiest way to delete obselete components from the list?

Thanks
KrisD
Back to top
View user's profile Send private message
isiticov
Site Admin


Joined: 21 Nov 2002
Posts: 2103

PostPosted: Tue Mar 22, 2005 7:27 am    Post subject: Reply with quote

What list do you mean? Internal lists (stored in TsiLang) are updated automatically.
Back to top
View user's profile Send private message
kdeberni



Joined: 17 Aug 2004
Posts: 11

PostPosted: Thu Mar 24, 2005 6:14 am    Post subject: Reply with quote

Hi,

I mean the list I receive after loading the properties from SIL file and applaying the BulidList() procedure. After this I have a list which contains all properties but also some obsolete (properties which do not exists on edited form because of some changes).

Is there an easy way to delete them?

Thanks
Kristijan Deberni
Back to top
View user's profile Send private message
isiticov
Site Admin


Joined: 21 Nov 2002
Posts: 2103

PostPosted: Thu Mar 24, 2005 6:17 am    Post subject: Reply with quote

After calling BuildList() all obsolete components/properties will be deleted from lists.
Back to top
View user's profile Send private message
kdeberni



Joined: 17 Aug 2004
Posts: 11

PostPosted: Thu Mar 24, 2005 10:23 am    Post subject: Reply with quote

Yes. You are absolutly right Smile.
Now I see that all works just like I want it.

Thanks a lot for all
Kristijan Deberni
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