Recent

Author Topic: My multilingual method for apps  (Read 6412 times)

winni

  • Hero Member
  • *****
  • Posts: 1594
Re: My multilingual method for apps
« Reply #15 on: April 07, 2020, 05:56:39 pm »
Hi!

There is another idea for a multilanguage app.

The idea is "stolen" from the UCSD compiler messages and was built in to the Ventura Publisher in a similar way.

Let the user select on of the languages for which a language file exists.

The language files contain 2 variables in one line:
an integer, a space as separator and a string - like

123 OK
124 cancel
125 continue
126 ....

And in your code you write something like
MyComponent.Caption := Msg (123);

Even with a small Integer you got room for 32.000 entries - so you can leave enough space inbetween for future enhancements.

And you can add (or delete) a language without going into  the code.

Plus: you need only one language file in the memory

Winni

Awkward

  • Jr. Member
  • **
  • Posts: 65
Re: My multilingual method for apps
« Reply #16 on: April 07, 2020, 06:21:28 pm »
And in your code you write something like
MyComponent.Caption := Msg (123);

And you ready to remember all your numeric codes or to check your dictionary to find needed text?

bytebites

  • Sr. Member
  • ****
  • Posts: 290
Re: My multilingual method for apps
« Reply #17 on: April 07, 2020, 06:29:39 pm »
And in your code you write something like
MyComponent.Caption := Msg (123);

And you ready to remember all your numeric codes or to check your dictionary to find needed text?

123

winni

  • Hero Member
  • *****
  • Posts: 1594
Re: My multilingual method for apps
« Reply #18 on: April 07, 2020, 07:19:50 pm »
Hi!

You just open a language file of a language, that you understand, in the IDE
and with one click you are there.

What helps is to group the messages by numbers, so let's say 100-199 are trvial button captions,
200-299 are questions for user interactions and so on.

Winni

Raul_ES

  • Full Member
  • ***
  • Posts: 169
  • My interests: Healthcare & Computers
    • My Linkedin Profile, you can add me to stay in contact.
Re: My multilingual method for apps
« Reply #19 on: April 16, 2020, 02:41:49 pm »
Thanks for your suggestions.

Personally I believe that one language text file for each form containing a grid structure for translated words it's the easier way I've been able to think of. And easier to mantein.


regards
Pharmacy + Chemistry + Biology + Healthcare + Computing

If you have any interest or project related with these areas feel free to contact me!

 

TinyPortal © 2005-2018