server/src/common/util/language.h

48 lines
1.5 KiB
C
Raw Normal View History

2001-01-25 10:37:55 +01:00
/* vi: set ts=2:
*
*
* Eressea PB(E)M host Copyright (C) 1998-2003
2001-01-25 10:37:55 +01:00
* Christian Schlittchen (corwin@amber.kn-bremen.de)
* Katja Zedel (katze@felidae.kn-bremen.de)
* Henning Peters (faroul@beyond.kn-bremen.de)
* Enno Rehling (enno@eressea-pbem.de)
* Ingo Wilken (Ingo.Wilken@informatik.uni-oldenburg.de)
*
* This program may not be used, modified or distributed without
* prior permission by the authors of Eressea.
*/
#ifndef MY_LOCALE_H
#define MY_LOCALE_H
#ifdef __cplusplus
extern "C" {
#endif
2001-01-25 10:37:55 +01:00
2002-09-02 22:36:12 +02:00
struct locale;
2001-01-25 10:37:55 +01:00
/** managing multiple locales: **/
2002-09-02 22:36:12 +02:00
extern struct locale * find_locale(const char * name);
extern struct locale * make_locale(const char * key);
2001-01-25 10:37:55 +01:00
/** operations on locales: **/
extern void locale_setstring(struct locale * lang, const char * key, const char * value);
extern const char * locale_getstring(const struct locale * lang, const char * key);
extern const char * locale_string(const struct locale * lang, const char * key); /* does fallback */
extern unsigned int locale_hashkey(const struct locale * lang);
extern const char * locale_name(const struct locale * lang);
2001-01-25 10:37:55 +01:00
extern const char * reverse_lookup(const struct locale * lang, const char * str);
extern const char * mkname(const char * namespc, const char * key);
extern void debug_language(const char * log);
#define LOC(lang, s) locale_string(lang, s)
2002-09-02 22:36:12 +02:00
extern struct locale * default_locale;
extern struct locale * locales;
extern struct locale * nextlocale(const struct locale * lang);
2001-05-20 10:41:11 +02:00
#ifdef __cplusplus
}
#endif
2001-01-25 10:37:55 +01:00
#endif