X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/a982ddd2020a7fbfa84c8e96feca2e6d1f1e967a..5679f3353ca517404f6f55178388e92930e312d4:/include/wx/wxchar.h diff --git a/include/wx/wxchar.h b/include/wx/wxchar.h index 63d5a33204..5832ca016c 100644 --- a/include/wx/wxchar.h +++ b/include/wx/wxchar.h @@ -101,6 +101,7 @@ typedef _TUCHAR wxUChar; #define wxUngetc _tungetc #define wxVfprint _vftprintf #define wxVprintf _vtprintf +#define wxVsscanf _vstscanf #define wxVsprintf _vstprintf // stdlib.h functions @@ -151,8 +152,16 @@ typedef unsigned __WCHAR_TYPE__ wxUChar; #define wxIsspace iswspace #define wxIsupper iswupper #define wxIsxdigit iswxdigit -#define wxTolower towlower -#define wxToupper towupper + +#if defined(__GLIBC__) && (__GLIBC__ == 2) && (__GLIBC_MINOR__ == 0) + // /usr/include/wctype.h incorrectly declares translations tables which + // provokes tons of compile-time warnings - try to correct this + #define wxTolower(wc) towctrans((wc), (wctrans_t)__ctype_tolower) + #define wxToupper(wc) towctrans((wc), (wctrans_t)__ctype_toupper) +#else + #define wxTolower towlower + #define wxToupper towupper +#endif // gcc/!gcc // string.h functions (wchar.h) #define wxStrcat wcscat @@ -265,6 +274,7 @@ typedef unsigned char wxUChar; #define wxUngetc ungetc #define wxVfprint vfprintf #define wxVprintf vprintf +#define wxVsscanf vsscanf #define wxVsprintf vsprintf // stdlib.h functions @@ -362,9 +372,16 @@ wxChar * WXDLLEXPORT wxSetlocale(int category, const wxChar *locale); #endif #ifdef wxNEED_WX_STDIO_H +#include #include +int WXDLLEXPORT wxPrintf(const wxChar *fmt, ...); +int WXDLLEXPORT wxVprintf(const wxChar *fmt, va_list argptr); +int WXDLLEXPORT wxFprintf(FILE *stream, const wxChar *fmt, ...); +int WXDLLEXPORT wxVfprintf(FILE *stream, const wxChar *fmt, va_list argptr); int WXDLLEXPORT wxSprintf(wxChar *buf, const wxChar *fmt, ...); int WXDLLEXPORT wxVsprintf(wxChar *buf, const wxChar *fmt, va_list argptr); +int WXDLLEXPORT wxSscanf(const wxChar *buf, const wxChar *fmt, ...); +int WXDLLEXPORT wxVsscanf(const wxChar *buf, const wxChar *fmt, va_list argptr); #endif #ifndef wxAtof