How to process with common titles

All announcements, questions and issues related to the TsiLang Components Suite.
Post Reply
Thomas J.
Posts: 129
Joined: Fri Jan 06, 2006 8:09 am

How to process with common titles

Post by Thomas J. »

Hello, I don't want to translate some title in each form, Is there a possibilty to translate it once and to reference in each form to the central point?

Thanks a lot
Thomas
I'm using C++ Builder 6, 6.1, Dispatcher, LangRT, and SIL file
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Post by isiticov »

This will require some "manual" work:
1. You can declare some global string variables in some common unit.
2. Create some function that will initialize these variables with the content.
3. Translate this function content using TsiLang Expert (File -> Source menu)
4. Under OnChangeLanguage event of TsiLang you will need to call this function.
5. In other forms you will need to initialize you UI controls with these variables and repeat this on every language change event.

But it will be dramatically simple to leave them as they are and just re-type translations. You can add your translations to Dictionary and later just use Auto-Translate to speed-up the translation.
Hope this helps.
Best regards,
Igor Siticov.
Thomas J.
Posts: 129
Joined: Fri Jan 06, 2006 8:09 am

Post by Thomas J. »

Thanks a lot, but how can I do this?
I add a new row in the Dictionary
"Betreff" (German), "Subject" (English)
and saved.
I opened my form and the Translation Editor add in the German column
"Betreff" and in the English column "Subjects" which is of course wrong.
I clicked on Suggestion and Auto Translate and Translate all.
But the wrong word "Subjects" was still the translation of "Betreff".

What did I wrong?
Thanks for your help
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Post by isiticov »

I can suppose that you have in dictionary the "Subjects" as translation for "Betreff". Just check the content of your dictionary.
Best regards,
Igor Siticov.
Thomas J.
Posts: 129
Joined: Fri Jan 06, 2006 8:09 am

Post by Thomas J. »

No its "Subject" sure! But if I remove "Subjects" that the cell is blank it works. So it works only for empty cells?
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Post by isiticov »

If the cell is not empty then it is not auto-translated.
Best regards,
Igor Siticov.
Thomas J.
Posts: 129
Joined: Fri Jan 06, 2006 8:09 am

Post by Thomas J. »

But if I have e.g 80 forms and on each form I have 2 titles with same title and now I have to change the 160 titles due to a mistake or new spelling reform. I have to change these 160 titles manuel?
There is no other solution?
isiticov
Site Admin
Posts: 2383
Joined: Thu Nov 21, 2002 3:17 pm

Post by isiticov »

You can export translations into SIL/SIB file and using SIL Editor use Auto-translate feature with "Overwrite existing items" option checked. This will try to re-translate the items that are already translated.
Hope this helps.
Best regards,
Igor Siticov.
Post Reply