SiLang components in inherited forms and packages

All announcements, questions and issues related to the TsiLang Components Suite.
Post Reply
kdeberni
Posts: 11
Joined: Tue Aug 17, 2004 12:18 pm

SiLang components in inherited forms and packages

Post by kdeberni »

Hi,

I am in proces of choosing multilanguage components\tool for a big project and in this moment I am testing siLang compnents for Delphi 7.

Our project is devided in packages which contatins inherited forms. That means package P1 contains form F1, package P2 containc form F2 inherited from form F1 with TsiLangLinked component which is connected to TSiLangDispatcher and TsiLang palced on separate datamodule.
Some of the strings are translated on form F3 from package P2.
Further I have package P3 with form F3 which is inherited from form F2 from package P2.
The idea was to translate all common strings on F2 and create a lot of forms inherited from F2 on which all translated strings will be translated automatecally and all what a programer have to do is to translate a new strings. (I hope you understand what I mean :-) ).

But, I am not able to get this. It means I configure all as I described but the form F3 is not translated at all. Even the strings from form F2 are not translated. On other forms which are not inherited are translated what means that traslating mechanizm works in the application.

So, do I have to configure it somehow special? Maybe just use some other components? Or....?

Thanks.

P.S. I tried also changing IsInheritedOwner property but nothing.
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Post by isiticov »

I would recommend you to try the following:
1. On Base form be sure to enter all translations.
2. After that create an inherited form and check if existing translations were kept.
There is also UseInheritedData property. Try to play with it.
But actually, I afraid, the scheme you described is really difficult for TsiLang.
BillHop3
Posts: 10
Joined: Wed Sep 29, 2004 3:04 pm

Post by BillHop3 »

Rather than us just playing with it, can you please explain how the new IsInheritedOwner and UseInheritedData properties are supposed to work?
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Post by isiticov »

IsInheritedOwner just indicates to TsiLang that its owner is inherited from some parent and while loading the form and component from stream (Delphi's reader) it is necessary to call ChangeLanguage.
From help file:
IsInheritedOwner property indicates if TsiLang component is placed on the form / module that is inherited from other form / module in order to correct handling of changing language. Set this property to True to inform TsiLang that it is placed on inherited owner. Note: this property won't be set automatically for inherited modules, you should set it by hand for each inherited module.
UseInheritedData indicates TsiLang do not store translations data into DFM but just use them from "parent" (ascendant) component.
Post Reply