home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
i18nv102.zip
/
SAMPLE
/
INFO
/
READ.ME
< prev
Wrap
Text File
|
1995-09-19
|
4KB
|
109 lines
===============================================================================
Internationalization (I18N) For OS/2
===============================================================================
Copyright IBM Corporation -- 1993, 1994, 1995
DISCLAIMER: This I18N package has been made available solely to gauge OS/2
developer interest in the industry standard XPG4 internationalization
programming model. This does not mean that IBM will introduce a product based
on the contents of this package. This package is not a full implementation of
the X/Open XPG4 specification and does not make any claims of XPG4 branding.
It implements only the portions of the XPG4 specification which deal with
internationalization.
X/Open is a trademark of the X/Open Company Limited.
===============================================================================
/************************/
/*** Contents ***/
/************************/
1. Overview
2. Files in this directory
3. How to run the sample program
4. How to compile the sample program
1. Overview
============
The sample program in this directory demonstrates the use of the NL_LANGINFO
and the LOCALECONV APIs. These two APIs are used to query and get information
about the current locale. See the technical reference for all of the
information you can obtain with these two calls.
2. Files in this directory
===========================
File Purpose
------------------------------------------------------------------------------
info.c Source code for the info sample program.
info.def Definition file needed for compiling the program.
info.mak Make file used to compile the sample.
info.exe Compiled version of the info sample.
build.cmd A command file which will compile and link the sample program.
read.me This file.
3. How to run the sample program
=================================
The following steps show how the program can be run.
1) Run the \i18n\bin\new_vars command file (or have the environment
variables already set).
2) Set the value of either LC_ALL or LANG to: en_us (US English).
Ex: set LANG=en_us
3) Execute the info.exe program.
Ex: info
4) The output from the program should be:
WARNING: Different values reported by this program are based on
different locale settings (LC_MONETARY, LC_TIME...)
Locale settings: ENUS437 ENUS437 ENUS437 ENUS437 ENUS437 ENUS437
Data from LOCALECONV:
---------------------
International monetary symbol: USD
Negative sign: -
Number of fractional digits (after decimal point): 2
Data from NL_LANGINFO:
----------------------
Days of the week: Sun Mon Tue Wed Thu Fri Sat
Radix character is: .
Thousands separator: ,
5) Experiment with changing the values of the LANG environment
variable. Also, you can modify the program to print out other
values returned by the two APIs.
4. How to compile the sample program
=====================================
NOTE: The sample program is already compiled for you. If you want to see the
behavior of the program, you can just run it. The following instructions
are needed only if you want to modify the program and recompile it.
To compile the sample application:
1) Make sure that the CSET/2 compiler and OS/2 toolkit are installed
correctly on your system.
2) cd to the directory which contains the info source files.
3) Type "build" at the command prompt.