ReactOS 0.4.16-dev-2104-gb84fa49
xlocinfo.h File Reference
#include <ctype.h>
#include <locale.h>
#include <wchar.h>
#include <yvals.h>
Include dependency graph for xlocinfo.h:

Go to the source code of this file.

Classes

struct  _Collvec
 
struct  _Ctypevec
 
struct  _Cvtvec
 

Macros

#define _XA   0x100
 
#define _XS   0x000
 
#define _BB   _CONTROL
 
#define _CN   _SPACE
 
#define _DI   _DIGIT
 
#define _LO   _LOWER
 
#define _PU   _PUNCT
 
#define _SP   _BLANK
 
#define _UP   _UPPER
 
#define _XD   _HEX
 
#define _X_ALL   LC_ALL
 
#define _X_COLLATE   LC_COLLATE
 
#define _X_CTYPE   LC_CTYPE
 
#define _X_MONETARY   LC_MONETARY
 
#define _X_NUMERIC   LC_NUMERIC
 
#define _X_TIME   LC_TIME
 
#define _X_MAX   LC_MAX
 
#define _X_MESSAGES   6
 
#define _NCAT   7
 
#define _CATMASK(n)   ((1 << (n)) >> 1)
 
#define _M_COLLATE   _CATMASK(_X_COLLATE)
 
#define _M_CTYPE   _CATMASK(_X_CTYPE)
 
#define _M_MONETARY   _CATMASK(_X_MONETARY)
 
#define _M_NUMERIC   _CATMASK(_X_NUMERIC)
 
#define _M_TIME   _CATMASK(_X_TIME)
 
#define _M_MESSAGES   _CATMASK(_X_MESSAGES)
 
#define _M_ALL   (_CATMASK(_NCAT) - 1)
 

Typedefs

typedef struct _Collvec _Collvec
 
typedef struct _Ctypevec _Ctypevec
 
typedef struct _Cvtvec _Cvtvec
 

Functions

_CRTIMP _Collvec __cdecl _Getcoll (void)
 
_CRTIMP _Ctypevec __cdecl _Getctype (void)
 
_CRTIMP _Cvtvec __cdecl _Getcvt (void)
 
_CRTIMP int __cdecl _Getdateorder (void)
 
_CRTIMP int __cdecl _Mbrtowc (wchar_t *, const char *, size_t, mbstate_t *, const _Cvtvec *)
 
_CRTIMP float __cdecl _Stof (const char *, char **, long)
 
_CRTIMP double __cdecl _Stod (const char *, char **, long)
 
_CRTIMP long double __cdecl _Stold (const char *, char **, long)
 
_CRTIMP int __cdecl _Strcoll (const char *, const char *, const char *, const char *, const _Collvec *)
 
_CRTIMP size_t __cdecl _Strxfrm (char *_String1, char *_End1, const char *, const char *, const _Collvec *)
 
_CRTIMP int __cdecl _Tolower (int, const _Ctypevec *)
 
_CRTIMP int __cdecl _Toupper (int, const _Ctypevec *)
 
_CRTIMP int __cdecl _Wcrtomb (char *, wchar_t, mbstate_t *, const _Cvtvec *)
 
_CRTIMP int __cdecl _Wcscoll (const wchar_t *, const wchar_t *, const wchar_t *, const wchar_t *, const _Collvec *)
 
_CRTIMP size_t __cdecl _Wcsxfrm (wchar_t *_String1, wchar_t *_End1, const wchar_t *, const wchar_t *, const _Collvec *)
 
_CRTIMP short __cdecl _Getwctype (wchar_t, const _Ctypevec *)
 
_CRTIMP const wchar_t *__cdecl _Getwctypes (const wchar_t *, const wchar_t *, short *, const _Ctypevec *)
 
_CRTIMP wchar_t __cdecl _Towlower (wchar_t, const _Ctypevec *)
 
_CRTIMP wchar_t __cdecl _Towupper (wchar_t, const _Ctypevec *)
 
_END_C_LIB_DECL _C_STD_END _C_LIB_DECL _CRTIMP void *__cdecl _Gettnames (void)
 
_CRTIMP char *__cdecl _Getdays (void)
 
_CRTIMP char *__cdecl _Getmonths (void)
 
_CRTIMP size_t __cdecl _Strftime (char *, size_t _Maxsize, const char *, const struct tm *, void *)
 
_END_C_LIB_DECL _C_LIB_DECL _locale_t __cdecl _GetLocaleForCP (unsigned int)
 

Macro Definition Documentation

◆ _BB

#define _BB   _CONTROL

Definition at line 20 of file xlocinfo.h.

◆ _CATMASK

#define _CATMASK (   n)    ((1 << (n)) >> 1)

Definition at line 39 of file xlocinfo.h.

◆ _CN

#define _CN   _SPACE

Definition at line 21 of file xlocinfo.h.

◆ _DI

#define _DI   _DIGIT

Definition at line 22 of file xlocinfo.h.

◆ _LO

#define _LO   _LOWER

Definition at line 23 of file xlocinfo.h.

◆ _M_ALL

#define _M_ALL   (_CATMASK(_NCAT) - 1)

Definition at line 46 of file xlocinfo.h.

◆ _M_COLLATE

#define _M_COLLATE   _CATMASK(_X_COLLATE)

Definition at line 40 of file xlocinfo.h.

◆ _M_CTYPE

#define _M_CTYPE   _CATMASK(_X_CTYPE)

Definition at line 41 of file xlocinfo.h.

◆ _M_MESSAGES

#define _M_MESSAGES   _CATMASK(_X_MESSAGES)

Definition at line 45 of file xlocinfo.h.

◆ _M_MONETARY

#define _M_MONETARY   _CATMASK(_X_MONETARY)

Definition at line 42 of file xlocinfo.h.

◆ _M_NUMERIC

#define _M_NUMERIC   _CATMASK(_X_NUMERIC)

Definition at line 43 of file xlocinfo.h.

◆ _M_TIME

#define _M_TIME   _CATMASK(_X_TIME)

Definition at line 44 of file xlocinfo.h.

◆ _NCAT

#define _NCAT   7

Definition at line 37 of file xlocinfo.h.

◆ _PU

#define _PU   _PUNCT

Definition at line 24 of file xlocinfo.h.

◆ _SP

#define _SP   _BLANK

Definition at line 25 of file xlocinfo.h.

◆ _UP

#define _UP   _UPPER

Definition at line 26 of file xlocinfo.h.

◆ _X_ALL

#define _X_ALL   LC_ALL

Definition at line 29 of file xlocinfo.h.

◆ _X_COLLATE

#define _X_COLLATE   LC_COLLATE

Definition at line 30 of file xlocinfo.h.

◆ _X_CTYPE

#define _X_CTYPE   LC_CTYPE

Definition at line 31 of file xlocinfo.h.

◆ _X_MAX

#define _X_MAX   LC_MAX

Definition at line 35 of file xlocinfo.h.

◆ _X_MESSAGES

#define _X_MESSAGES   6

Definition at line 36 of file xlocinfo.h.

◆ _X_MONETARY

#define _X_MONETARY   LC_MONETARY

Definition at line 32 of file xlocinfo.h.

◆ _X_NUMERIC

#define _X_NUMERIC   LC_NUMERIC

Definition at line 33 of file xlocinfo.h.

◆ _X_TIME

#define _X_TIME   LC_TIME

Definition at line 34 of file xlocinfo.h.

◆ _XA

#define _XA   0x100

This file has no copyright assigned and is placed in the Public Domain. This file is part of the w64 mingw-runtime package. No warranty is given; refer to the file DISCLAIMER within this package.

Definition at line 18 of file xlocinfo.h.

◆ _XD

#define _XD   _HEX

Definition at line 27 of file xlocinfo.h.

◆ _XS

#define _XS   0x000

Definition at line 19 of file xlocinfo.h.

Typedef Documentation

◆ _Collvec

◆ _Ctypevec

◆ _Cvtvec

Function Documentation

◆ _Getcoll()

_CRTIMP _Collvec __cdecl _Getcoll ( void  )

◆ _Getctype()

_CRTIMP _Ctypevec __cdecl _Getctype ( void  )

◆ _Getcvt()

_CRTIMP _Cvtvec __cdecl _Getcvt ( void  )

◆ _Getdateorder()

_CRTIMP int __cdecl _Getdateorder ( void  )

◆ _Getdays()

_CRTIMP char *__cdecl _Getdays ( void  )

Definition at line 678 of file locale.c.

679{
681 int i, len, size = 0;
682 char *out;
683
684 TRACE("\n");
685
686 for(i=0; i<7; i++) {
687 size += strlen(cur->str.names.short_wday[i]) + 1;
688 size += strlen(cur->str.names.wday[i]) + 1;
689 }
690 out = malloc(size+1);
691 if(!out)
692 return NULL;
693
694 size = 0;
695 for(i=0; i<7; i++) {
696 out[size++] = ':';
697 len = strlen(cur->str.names.short_wday[i]);
698 memcpy(&out[size], cur->str.names.short_wday[i], len);
699 size += len;
700
701 out[size++] = ':';
702 len = strlen(cur->str.names.wday[i]);
703 memcpy(&out[size], cur->str.names.wday[i], len);
704 size += len;
705 }
706 out[size] = '\0';
707
708 return out;
709}
#define malloc
Definition: debug_ros.c:4
#define NULL
Definition: types.h:112
_ACRTIMP size_t __cdecl strlen(const char *)
Definition: string.c:1592
pthreadlocinfo CDECL get_locinfo(void)
Definition: locale.c:635
FxCollectionEntry * cur
GLsizeiptr size
Definition: glext.h:5919
GLenum GLsizei len
Definition: glext.h:6722
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
#define memcpy(s1, s2, n)
Definition: mkisofs.h:878
#define TRACE(s)
Definition: solgame.cpp:4
struct __lc_time_data * lc_time_curr
Definition: corecrt.h:309
wchar_t tm const _CrtWcstime_Writes_and_advances_ptr_ count wchar_t ** out
Definition: wcsftime.cpp:383

◆ _GetLocaleForCP()

◆ _Getmonths()

_CRTIMP char *__cdecl _Getmonths ( void  )

Definition at line 752 of file locale.c.

753{
755 int i, len, size = 0;
756 char *out;
757
758 TRACE("\n");
759
760 for(i=0; i<12; i++) {
761 size += strlen(cur->str.names.short_mon[i]) + 1;
762 size += strlen(cur->str.names.mon[i]) + 1;
763 }
764 out = malloc(size+1);
765 if(!out)
766 return NULL;
767
768 size = 0;
769 for(i=0; i<12; i++) {
770 out[size++] = ':';
771 len = strlen(cur->str.names.short_mon[i]);
772 memcpy(&out[size], cur->str.names.short_mon[i], len);
773 size += len;
774
775 out[size++] = ':';
776 len = strlen(cur->str.names.mon[i]);
777 memcpy(&out[size], cur->str.names.mon[i], len);
778 size += len;
779 }
780 out[size] = '\0';
781
782 return out;
783}

◆ _Gettnames()

Definition at line 826 of file locale.c.

827{
829 unsigned int i, len, size = sizeof(__lc_time_data);
830
831 TRACE("\n");
832
833 for(i=0; i<ARRAY_SIZE(cur->str.str); i++)
834 size += strlen(cur->str.str[i])+1;
835#if _MSVCR_VER >= 110
836 for(i=0; i<ARRAY_SIZE(cur->wstr.wstr); i++)
837 size += (wcslen(cur->wstr.wstr[i]) + 1) * sizeof(wchar_t);
838#endif
839
840 ret = malloc(size);
841 if(!ret)
842 return NULL;
843 memcpy(ret, cur, sizeof(*ret));
844
845 size = 0;
846 for(i=0; i<ARRAY_SIZE(cur->str.str); i++) {
847 len = strlen(cur->str.str[i])+1;
848 memcpy(&ret->data[size], cur->str.str[i], len);
849 ret->str.str[i] = &ret->data[size];
850 size += len;
851 }
852#if _MSVCR_VER >= 110
853 for(i=0; i<ARRAY_SIZE(cur->wstr.wstr); i++) {
854 len = (wcslen(cur->wstr.wstr[i]) + 1) * sizeof(wchar_t);
855 memcpy(&ret->data[size], cur->wstr.wstr[i], len);
856 ret->wstr.wstr[i] = (wchar_t*)&ret->data[size];
857 size += len;
858 }
859#endif
860
861 return ret;
862}
#define ARRAY_SIZE(A)
Definition: main.h:20
_ACRTIMP size_t __cdecl wcslen(const wchar_t *)
Definition: wcs.c:2983
return ret
Definition: mutex.c:146

Referenced by test__Gettnames().

◆ _Getwctype()

_CRTIMP short __cdecl _Getwctype ( wchar_t  ,
const _Ctypevec  
)

◆ _Getwctypes()

_CRTIMP const wchar_t *__cdecl _Getwctypes ( const wchar_t ,
const wchar_t ,
short ,
const _Ctypevec  
)

◆ _Mbrtowc()

_CRTIMP int __cdecl _Mbrtowc ( wchar_t ,
const char ,
size_t  ,
mbstate_t ,
const _Cvtvec  
)

◆ _Stod()

_CRTIMP double __cdecl _Stod ( const char ,
char **  ,
long   
)

◆ _Stof()

_CRTIMP float __cdecl _Stof ( const char ,
char **  ,
long   
)

◆ _Stold()

_CRTIMP long double __cdecl _Stold ( const char ,
char **  ,
long   
)

◆ _Strcoll()

_CRTIMP int __cdecl _Strcoll ( const char ,
const char ,
const char ,
const char ,
const _Collvec  
)

◆ _Strftime()

_CRTIMP size_t __cdecl _Strftime ( char str,
size_t  _Maxsize,
const char format,
const struct tm mstm,
void time_data 
)

Definition at line 1528 of file time.c.

1530{
1531 return strftime_helper(str, max, format, mstm, time_data, NULL);
1532}
static size_t strftime_helper(char *str, size_t max, const char *format, const struct tm *mstm, __lc_time_data *time_data, _locale_t loc)
Definition: time.c:1466
const WCHAR * str
Definition: format.c:58
#define max(a, b)
Definition: svc.c:63

Referenced by strftime().

◆ _Strxfrm()

_CRTIMP size_t __cdecl _Strxfrm ( char _String1,
char _End1,
const char ,
const char ,
const _Collvec  
)

◆ _Tolower()

_CRTIMP int __cdecl _Tolower ( int  ,
const _Ctypevec  
)

◆ _Toupper()

_CRTIMP int __cdecl _Toupper ( int  ,
const _Ctypevec  
)

◆ _Towlower()

_CRTIMP wchar_t __cdecl _Towlower ( wchar_t  ,
const _Ctypevec  
)

◆ _Towupper()

_CRTIMP wchar_t __cdecl _Towupper ( wchar_t  ,
const _Ctypevec  
)

◆ _Wcrtomb()

_CRTIMP int __cdecl _Wcrtomb ( char ,
wchar_t  ,
mbstate_t ,
const _Cvtvec  
)

◆ _Wcscoll()

_CRTIMP int __cdecl _Wcscoll ( const wchar_t ,
const wchar_t ,
const wchar_t ,
const wchar_t ,
const _Collvec  
)

◆ _Wcsxfrm()

_CRTIMP size_t __cdecl _Wcsxfrm ( wchar_t _String1,
wchar_t _End1,
const wchar_t ,
const wchar_t ,
const _Collvec  
)