Solved

Need suggestion for message catalog(I18N) on Windows?

Posted on 2003-11-05
2
197 Views
Last Modified: 2010-04-15
Hello All,
      I am working on a project where I need to port source code from Linux to Windows.The Linux sources uses api's like catopen, catgets for supporting multi-language support with the help of message catalog.
      Could somebody suggest what could be the best ways to port the same on WIndows?Some were saying I
need to create a resource with String Table where I put all the messages.
       Could someone explain me in detail about this?Are there any Windows equivalent APIs available through which I can retrieve those strings inside my program?

         Thanks for your help.
Regards,
Karthik
0
Comment
Question by:karthikd22
2 Comments
 
LVL 45

Expert Comment

by:Kdo
ID: 9689138

Many of the linux APIs will have a direct replacement in the Windows world.  (Some won't.)  For those that do, a quick way to incorporate them is to define the API as a macro.

linuxapi (p1, p2, p3);

Windows macro:

#define linuxapi(p1,p2,p3) WindowsApi(p1,p2,p3)

Note that for some of these macros you might have to assume certain parameters, drop some, or change the order.

This should go a long way toward getting your conversion rolling.

Good Luck!
Kent

0
 
LVL 5

Accepted Solution

by:
g0rath earned 250 total points
ID: 9689443
Is a throw away port, or will you need to support Linux clients and Windows clients?

If you need to support both, Mozilla uses platform independent string resources. Take a look.

http://www.mozilla.org/docs/refList/i18n/allxpstr-h.html
0

Featured Post

Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
posix semaphore deadlock 13 123
Estimate porting issues. 9 119
Console based application in Linux 1 89
Can case within switch statement specify range of values ? 3 81
Preface I don't like visual development tools that are supposed to write a program for me. Even if it is Xcode and I can use Interface Builder. Yes, it is a perfect tool and has helped me a lot, mainly, in the beginning, when my programs were small…
Windows programmers of the C/C++ variety, how many of you realise that since Window 9x Microsoft has been lying to you about what constitutes Unicode (http://en.wikipedia.org/wiki/Unicode)? They will have you believe that Unicode requires you to use…
Video by: Grant
The goal of this video is to provide viewers with basic examples to understand and use while-loops in the C programming language.
The goal of this video is to provide viewers with basic examples to understand how to create, access, and change arrays in the C programming language.

786 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question