English Amiga Board


Go Back   English Amiga Board > Coders > Coders. General

 
 
Thread Tools
Old 27 December 2018, 22:48   #1
tygre
Returning fan!
 
tygre's Avatar
 
Join Date: Jan 2011
Location: Montréal, QC, Canada
Posts: 1,434
Best Practices in Localizing a Program?

Hi all!

Hope that you had a merry Xmas

During the holidays, I would like to localize AmiModRadio... I have read a lot about .ct and .cd files, about CatComp, and other tools... but did not find much about concretely localizing a program...

Here is what I have: a program divided into 22 C source files and SimpleCat. Now, should I create one .ct file (.cs file in the SimpleCat) per C source file OR one and only one .ct file for all the 22 C source files?

I feel that this one file would become super large...

Thanks for your suggestions!
tygre is offline  
Old 28 December 2018, 08:14   #2
Krashan
Hardware Designer
 
Join Date: Aug 2018
Location: Bialystok/Poland
Age: 51
Posts: 180
If SimpleCat can merge those 22 files before generating .catalog, why not.
Krashan is offline  
Old 28 December 2018, 09:29   #3
thomas
Registered User
 
thomas's Avatar
 
Join Date: Jan 2002
Location: Germany
Posts: 7,025
You make one .cd file for your program. From that you generate a .h file with CatComp or any other utility. The .h file can be used in your source code files.

I even prefer to make my own locale.c which handles all the localization. The corresponding locale.h is then used in the other source files. It only contains the string names.

There is an example: http://thomas-rapp.homepage.t-online...les/locale.lha
thomas is offline  
Old 29 December 2018, 05:38   #4
tygre
Returning fan!
 
tygre's Avatar
 
Join Date: Jan 2011
Location: Montréal, QC, Canada
Posts: 1,434
Hi Krashan and Thomas and thanks for your answers!

Yes, I discovered that SimpleCat has this very neat feature: it can extract strings from C source files and combine them all into one .cs file

So, I have now one .cs file, from which I can generate one .cd, .ct, and the .h/.c code necessary for the localisation to work!

Thank you SimpleCat!
Cheers!
tygre is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
External windows program communicating with program running inside WinUAE xxxxx support.WinUAE 10 19 February 2013 09:27
Paint program or program....... amigagenie request.Apps 2 29 January 2013 19:56
For a beginner what Program and Program language would you recommend? amigang New to Emulation or Amiga scene 5 27 March 2012 13:06
Best practices for direct hardware programming ? weiju Coders. Asm / Hardware 27 31 October 2011 13:10
Calling another program from a compiled Amos program...? andyr support.Apps 3 24 October 2004 23:47

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 07:09.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.11771 seconds with 13 queries