OWLNext    7.0
Borland's Object Windows Library for the modern age
Loading...
Searching...
No Matches
localeco.cpp
Go to the documentation of this file.
1//----------------------------------------------------------------------------
2// Borland WinSys Library
3// Copyright (c) 1994, 1996 by Borland International, All Rights Reserved
4//
5/// \file
6/// TLocaleString default NLS compare function - used only if non-OLE2
7//----------------------------------------------------------------------------
8#include <owl/pch.h>
9#include <owl/defs.h>
10#include <owl/lclstrng.h>
11
12namespace owl {
13
14
15/// Returns the system language ID, which can be the same as the UserLangId.
18{
19 return ::GetSystemDefaultLangID();
20}
21
22/// Returns the user language ID. For single user systems, this is the same as
23/// LangSysDefault. The language ID is a predefined number that represents a base
24/// language and dialect.
27{
28 return ::GetUserDefaultLangID();
29}
30
31/// This function may be re-implemented with enhanced NLS support in another module.
32/// \note That module must be linked in before the library, to override this default
33/// implementation.
34int
36{
37 return ::CompareString(lang, NORM_IGNORECASE | NORM_IGNORENONSPACE, s1, -1, s2, -1) - 2;
38}
39
40
41} // OWL namespace
42
TLocaleString - localized name support.
Object Windows Library (OWLNext Core)
Definition animctrl.h:22
owl::uint16 TLangId
Holds a language ID, a predefined number that represents a base language and dialect.
Definition lclstrng.h:26
char tchar
Definition defs.h:77
General definitions used by all ObjectWindows programs.
static int CompareLang(const tchar *s1, const tchar *s2, TLangId)
This function may be re-implemented with enhanced NLS support in another module.
Definition localeco.cpp:35
static TLangId GetSystemLangId()
platform-dependent implementation
Definition localeco.cpp:17
static TLangId GetUserLangId()
platform-dependent implementation
Definition localeco.cpp:26