Anope IRC Services  Version 2.0
language.h
Go to the documentation of this file.
1 /*
2  *
3  * (C) 2008-2014 Anope Team
4  * Contact us at team@anope.org
5  *
6  * Please read COPYING and README for further details.
7  *
8  */
9 
10 #include "anope.h"
11 
12 namespace Language
13 {
14 
15  /* Languages we support as configured in services.conf. They are
16  * added to this list if we detect a language exists in the correct
17  * location for each language.
18  */
19  extern CoreExport std::vector<Anope::string> Languages;
20 
21  /* Domains to search when looking for translations other than the
22  * default "anope domain. This is used by modules who add their own
23  * language files (and thus domains) to Anope. If a module is loaded
24  * and we detect a language file exists for at least one of the supported
25  * languages for the module, then we add the module's domain (its name)
26  * here.
27  *
28  * When strings are translated they are checked against all domains.
29  */
30  extern std::vector<Anope::string> Domains;
31 
35  extern void InitLanguages();
36 
41  extern CoreExport const char *Translate(const char *string);
42 
48  extern CoreExport const char *Translate(User *u, const char *string);
49 
55  extern CoreExport const char *Translate(const NickCore *nc, const char *string);
56 
62  extern CoreExport const char *Translate(const char *lang, const char *string);
63 
64 } // namespace Language
65 
66 /* Commonly used language strings */
67 #define MORE_INFO _("\002%s%s HELP %s\002 for more information.")
68 #define BAD_USERHOST_MASK _("Mask must be in the form \037user\037@\037host\037.")
69 #define BAD_EXPIRY_TIME _("Invalid expiry time.")
70 #define USERHOST_MASK_TOO_WIDE _("%s coverage is too wide; Please use a more specific mask.")
71 #define READ_ONLY_MODE _("Services are in read-only mode!")
72 #define PASSWORD_INCORRECT _("Password incorrect.")
73 #define ACCESS_DENIED _("Access denied.")
74 #define MORE_OBSCURE_PASSWORD _("Please try again with a more obscure password. Passwords should be at least\n" \
75  "five characters long, should not be something easily guessed\n" \
76  "(e.g. your real name or your nick), and cannot contain the space or tab characters.")
77 #define PASSWORD_TOO_LONG _("Your password is too long. Please try again with a shorter password.")
78 #define NICK_NOT_REGISTERED _("Your nick isn't registered.")
79 #define NICK_X_NOT_REGISTERED _("Nick \002%s\002 isn't registered.")
80 #define NICK_X_NOT_IN_USE _("Nick \002%s\002 isn't currently in use.")
81 #define NICK_X_NOT_ON_CHAN _("\002%s\002 is not currently on channel %s.")
82 #define NICK_X_SUSPENDED _("Nick %s is currently suspended.")
83 #define CHAN_X_SUSPENDED _("Channel %s is currently suspended.")
84 #define CHAN_X_NOT_REGISTERED _("Channel \002%s\002 isn't registered.")
85 #define CHAN_X_NOT_IN_USE _("Channel \002%s\002 doesn't exist.")
86 #define NICK_IDENTIFY_REQUIRED _("Password authentication required for that command.")
87 #define MAIL_X_INVALID _("\002%s\002 is not a valid e-mail address.")
88 #define UNKNOWN _("<unknown>")
89 #define NO_EXPIRE _("does not expire")
90 #define LIST_INCORRECT_RANGE _("Incorrect range specified. The correct syntax is \002#\037from\037-\037to\037\002.")
91 #define NICK_IS_REGISTERED _("This nick is owned by someone else. Please choose another.\n" \
92  "(If this is your nick, type \002%s%s IDENTIFY \037password\037\002.)")
93 #define NICK_IS_SECURE _("This nickname is registered and protected. If it is your\n" \
94  "nick, type \002%s%s IDENTIFY \037password\037\002. Otherwise,\n" \
95  "please choose a different nick.")
96 #define FORCENICKCHANGE_NOW _("This nickname has been registered; you may not use it.")
97 #define NICK_CANNOT_BE_REGISTERED _("Nickname \002%s\002 may not be registered.")
98 #define NICK_ALREADY_REGISTERED _("Nickname \002%s\002 is already registered!")
99 #define NICK_SET_DISPLAY_CHANGED _("The new display is now \002%s\002.")
100 #define NICK_CONFIRM_INVALID _("Invalid passcode has been entered, please check the e-mail again, and retry.")
101 #define CHAN_NOT_ALLOWED_TO_JOIN _("You are not permitted to be on this channel.")
102 #define CHAN_X_INVALID _("Channel %s is not a valid channel.")
103 #define CHAN_REACHED_CHANNEL_LIMIT _("Sorry, you have already reached your limit of \002%d\002 channels.")
104 #define CHAN_EXCEEDED_CHANNEL_LIMIT _("Sorry, you have already exceeded your limit of \002%d\002 channels.")
105 #define CHAN_SYMBOL_REQUIRED _("Please use the symbol of \002#\002 when attempting to register.")
106 #define CHAN_SETTING_CHANGED _("%s for %s set to %s.")
107 #define CHAN_SETTING_UNSET _("%s for %s unset.")
108 #define CHAN_ACCESS_LEVEL_RANGE _("Access level must be between %d and %d inclusive.")
109 #define CHAN_INFO_HEADER _("Information for channel \002%s\002:")
110 #define CHAN_EXCEPTED _("\002%s\002 matches an except on %s and cannot be banned until the except has been removed.")
111 #define MEMO_NEW_X_MEMO_ARRIVED _("There is a new memo on channel %s.\n" \
112  "Type \002%s%s READ %s %d\002 to read it.")
113 #define MEMO_NEW_MEMO_ARRIVED _("You have a new memo from %s.\n" \
114  "Type \002%s%s READ %d\002 to read it.")
115 #define MEMO_HAVE_NO_MEMOS _("You have no memos.")
116 #define MEMO_X_HAS_NO_MEMOS _("%s has no memos.")
117 #define MEMO_SEND_DISABLED _("Sorry, memo sending is temporarily disabled.")
118 #define MEMO_HAVE_NO_NEW_MEMOS _("You have no new memos.")
119 #define MEMO_X_HAS_NO_NEW_MEMOS _("%s has no new memos.")
120 #define BOT_DOES_NOT_EXIST _("Bot \002%s\002 does not exist.")
121 #define BOT_NOT_ASSIGNED _("You must assign a bot to the channel before using this command.")
122 #define BOT_NOT_ON_CHANNEL _("Bot is not on channel \002%s\002.")
123 #define HOST_SET_ERROR _("A vHost must be in the format of a valid hostname.")
124 #define HOST_SET_IDENT_ERROR _("A vHost ident must be in the format of a valid ident.")
125 #define HOST_SET_TOOLONG _("Error! The vHost is too long, please use a hostname shorter than %d characters.")
126 #define HOST_SET_IDENTTOOLONG _("Error! The vHost ident is too long, please use an ident shorter than %d characters.")
127 #define HOST_NOT_ASSIGNED _("Please contact an Operator to get a vHost assigned to this nick.")
128 #define HOST_NO_VIDENT _("Your IRCd does not support vIdent's, if this is incorrect, please report this as a possible bug")
129 
Definition: users.h:34
void InitLanguages()
Definition: language.cpp:26
CoreExport std::vector< Anope::string > Languages
Definition: language.cpp:23
CoreExport const char * Translate(const char *string)
Definition: language.cpp:59
#define CoreExport
Definition: services.h:62
std::vector< Anope::string > Domains
Definition: language.cpp:24