home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 1998 May / Pcwk5b98.iso / Borland / Cplus45 / BC45 / INC.PAK / LOCALE.H < prev    next >
C/C++ Source or Header  |  1995-08-29  |  3KB  |  144 lines

  1. /*  locale.h
  2.  
  3. */
  4.  
  5. /*
  6.  *      C/C++ Run Time Library - Version 6.5
  7.  *
  8.  *      Copyright (c) 1987, 1994 by Borland International
  9.  *      All Rights Reserved.
  10.  *
  11.  */
  12.  
  13. #ifndef __LOCALE_H
  14. #define __LOCALE_H
  15.  
  16. #if !defined(___DEFS_H)
  17. #include <_defs.h>
  18. #endif
  19.  
  20. #ifndef NULL
  21. #include <_null.h>
  22. #endif
  23.  
  24.  
  25. #if !defined(RC_INVOKED)
  26.  
  27. #if defined(__STDC__)
  28. #pragma warn -nak
  29. #endif
  30.  
  31. #endif  /* !RC_INVOKED */
  32.  
  33.  
  34. #ifndef _SIZE_T
  35. #    define _SIZE_T
  36. typedef unsigned size_t;
  37. #endif
  38.  
  39.  
  40. #define LC_ALL      0
  41. #define LC_COLLATE  1
  42. #define LC_CTYPE    2
  43. #define LC_MONETARY 3
  44. #define LC_NUMERIC  4
  45. #define LC_TIME     5
  46. #define LC_MESSAGES 6
  47. #define LC_userdef  7
  48. #define LC_LAST     LC_userdef
  49.  
  50. #if !defined(__FLAT__)
  51.  
  52. struct lconv {
  53.  
  54.    char _FAR *decimal_point;
  55.    char _FAR *thousands_sep;
  56.    char _FAR *grouping;
  57.    char _FAR *int_curr_symbol;
  58.    char _FAR *currency_symbol;
  59.    char _FAR *mon_decimal_point;
  60.    char _FAR *mon_thousands_sep;
  61.    char _FAR *mon_grouping;
  62.    char _FAR *positive_sign;
  63.    char _FAR *negative_sign;
  64.    char int_frac_digits;
  65.    char frac_digits;
  66.    char p_cs_precedes;
  67.    char p_sep_by_space;
  68.    char n_cs_precedes;
  69.    char n_sep_by_space;
  70.    char p_sign_posn;
  71.    char n_sign_posn;
  72. };
  73.  
  74. #ifdef __cplusplus
  75. extern "C" {
  76. #endif
  77. char _FAR * _CType _FARFUNC setlocale( int __category, const char _FAR *__locale );
  78. char _FAR * _CType _FARFUNC _lsetlocale( int __category, const char _FAR *__locale );
  79. struct lconv _FAR * _CType localeconv( void );
  80. struct lconv _FAR * _CType _FARFUNC _llocaleconv( void );
  81. #ifdef __cplusplus
  82. }
  83. #endif
  84.  
  85. #else  /* defined __FLAT__ */
  86.  
  87. #pragma option -a-
  88.  
  89. struct lconv {
  90.  
  91.    char *decimal_point;
  92.    char *thousands_sep;
  93.    char *grouping;
  94.    char *int_curr_symbol;
  95.    char *currency_symbol;
  96.    char *mon_decimal_point;
  97.    char *mon_thousands_sep;
  98.    char *mon_grouping;
  99.    char *positive_sign;
  100.    char *negative_sign;
  101.    char int_frac_digits;
  102.    char frac_digits;
  103.    char p_cs_precedes;
  104.    char p_sep_by_space;
  105.    char n_cs_precedes;
  106.    char n_sep_by_space;
  107.    char p_sign_posn;
  108.    char n_sign_posn;
  109. };
  110.  
  111. #ifdef __cplusplus
  112. extern "C" {
  113. #endif
  114. char *         _RTLENTRY _EXPFUNC setlocale( int __category, const char _FAR *__locale );
  115. char *         _RTLENTRY _EXPFUNC _lsetlocale( int __category, const char _FAR *__locale );
  116. struct lconv * _RTLENTRY _EXPFUNC localeconv( void );
  117. struct lconv * _RTLENTRY _EXPFUNC _llocaleconv( void );
  118. #ifdef __cplusplus
  119. }
  120. #endif
  121.  
  122. #pragma option -a. /* restore default packing */
  123.  
  124.  
  125. #endif  /* __FLAT__ */
  126.  
  127. #if defined( __USELOCALES__ )
  128. #define setlocale  _lsetlocale
  129. #define localeconv _llocaleconv
  130. #endif
  131.  
  132.  
  133. #if !defined(RC_INVOKED)
  134.  
  135. #if defined(__STDC__)
  136. #pragma warn .nak
  137. #endif
  138.  
  139. #endif  /* !RC_INVOKED */
  140.  
  141.  
  142. #endif  /* __LOCALE_H */
  143.  
  144.