/src/ki18n/src/i18n/klocalizedstring.h
Line | Count | Source |
1 | | /* This file is part of the KDE libraries |
2 | | SPDX-FileCopyrightText: 2006, 2013 Chusslove Illich <caslav.ilic@gmx.net> |
3 | | |
4 | | SPDX-License-Identifier: LGPL-2.0-or-later |
5 | | */ |
6 | | #ifndef KLOCALIZEDSTRING_H |
7 | | #define KLOCALIZEDSTRING_H |
8 | | |
9 | | #include <ki18n_export.h> |
10 | | |
11 | | #include <QChar> |
12 | | #include <QLatin1Char> |
13 | | #include <QSet> |
14 | | #include <QString> |
15 | | #include <QStringList> |
16 | | |
17 | | #include <kuitsetup.h> |
18 | | |
19 | | // enforce header to be parsed before redefining i18n* with preprocessor macros |
20 | | // depending on TRANSLATION_DOMAIN (see bottom of file) |
21 | | #include <klocalizedcontext.h> |
22 | | |
23 | | class KLocalizedStringPrivate; |
24 | | class KLazyLocalizedString; |
25 | | |
26 | | /*! |
27 | | * \class KLocalizedString |
28 | | * \inmodule KI18n |
29 | | * |
30 | | * \brief Class for producing and handling localized messages. |
31 | | * |
32 | | * KLocalizedString handles translation and |
33 | | * argument substitution and formatting of user-visible text. |
34 | | * |
35 | | * KLocalizedString instances are usually not constructed directly, |
36 | | * but through one of the wrapper *i18n* calls. |
37 | | * |
38 | | * For detailed information on how to use KI18n functions please refer |
39 | | * to the \l {https://invent.kde.org/frameworks/ki18n/-/blob/master/docs/programmers-guide.md}{Programmer's Guide} |
40 | | */ |
41 | | class KI18N_EXPORT KLocalizedString |
42 | | { |
43 | | friend class KLocalizedStringPrivate; |
44 | | friend class KLazyLocalizedString; |
45 | | |
46 | | friend KLocalizedString KI18N_EXPORT ki18n(const char *text); |
47 | | friend KLocalizedString KI18N_EXPORT ki18nc(const char *context, const char *text); |
48 | | friend KLocalizedString KI18N_EXPORT ki18np(const char *singular, const char *plural); |
49 | | friend KLocalizedString KI18N_EXPORT ki18ncp(const char *context, const char *singular, const char *plural); |
50 | | friend KLocalizedString KI18N_EXPORT ki18nd(const char *domain, const char *text); |
51 | | friend KLocalizedString KI18N_EXPORT ki18ndc(const char *domain, const char *context, const char *text); |
52 | | friend KLocalizedString KI18N_EXPORT ki18ndp(const char *domain, const char *singular, const char *plural); |
53 | | friend KLocalizedString KI18N_EXPORT ki18ndcp(const char *domain, const char *context, const char *singular, const char *plural); |
54 | | |
55 | | friend KLocalizedString KI18N_EXPORT kxi18n(const char *text); |
56 | | friend KLocalizedString KI18N_EXPORT kxi18nc(const char *context, const char *text); |
57 | | friend KLocalizedString KI18N_EXPORT kxi18np(const char *singular, const char *plural); |
58 | | friend KLocalizedString KI18N_EXPORT kxi18ncp(const char *context, const char *singular, const char *plural); |
59 | | friend KLocalizedString KI18N_EXPORT kxi18nd(const char *domain, const char *text); |
60 | | friend KLocalizedString KI18N_EXPORT kxi18ndc(const char *domain, const char *context, const char *text); |
61 | | friend KLocalizedString KI18N_EXPORT kxi18ndp(const char *domain, const char *singular, const char *plural); |
62 | | friend KLocalizedString KI18N_EXPORT kxi18ndcp(const char *domain, const char *context, const char *singular, const char *plural); |
63 | | |
64 | | public: |
65 | | /*! |
66 | | * Construct an empty message. |
67 | | * |
68 | | * Direct construction is used when another KLocalizedString instance, |
69 | | * obtained by one of ki18n* calls, should later be assigned |
70 | | * to directly constructed instance. |
71 | | * Before the assignment happens, directly constructed instance |
72 | | * is not valid for finalization by toString methods. |
73 | | * |
74 | | * \sa isEmpty |
75 | | */ |
76 | | explicit KLocalizedString(); |
77 | | |
78 | | KLocalizedString(const KLocalizedString &rhs); |
79 | | |
80 | | KLocalizedString &operator=(const KLocalizedString &rhs); |
81 | | |
82 | | ~KLocalizedString(); |
83 | | |
84 | | /*! |
85 | | * Check whether the message is empty. |
86 | | * |
87 | | * The message is considered empty if the object was constructed |
88 | | * via the default constructor. |
89 | | * |
90 | | * Empty messages are not valid for finalization. |
91 | | * The behavior of calling toString on them is undefined. |
92 | | * In debug mode, an error mark may appear in the returned string. |
93 | | * |
94 | | * Returns \c true if the message is empty, \c false otherwise |
95 | | */ |
96 | | bool isEmpty() const; |
97 | | |
98 | | /*! |
99 | | * Finalize the translation. |
100 | | * |
101 | | * Creates translated QString, with placeholders substituted |
102 | | * by arguments given by KLocalizedString::subs methods. |
103 | | * Translated text is searched for and arguments are formatted |
104 | | * based on the global locale. |
105 | | * |
106 | | * If there was any mismatch between placeholders and arguments, |
107 | | * in debug mode the returned string may contain error marks. |
108 | | * |
109 | | * Returns finalized translation |
110 | | */ |
111 | | Q_REQUIRED_RESULT QString toString() const; |
112 | | |
113 | | /*! |
114 | | * Like toString, but look for translation only in given languages. |
115 | | * |
116 | | * Given languages override languages defined by the global locale, |
117 | | * and any languages set earlier using withLanguages. |
118 | | * If \a languages is empty, original message is returned. |
119 | | * |
120 | | * \a languages list of language codes (by decreasing priority) |
121 | | * Returns finalized translation |
122 | | */ |
123 | | Q_REQUIRED_RESULT QString toString(const QStringList &languages) const; |
124 | | |
125 | | /*! |
126 | | * Like toString, but look for translation in the given domain. |
127 | | * |
128 | | * Given domain overrides any set earlier using withDomain. |
129 | | * |
130 | | * \a domain the translation domain |
131 | | * |
132 | | * Returns finalized translation |
133 | | */ |
134 | | Q_REQUIRED_RESULT QString toString(const char *domain) const; |
135 | | |
136 | | /*! |
137 | | * Like toString, but resolve KUIT markup into given visual format. |
138 | | * |
139 | | * Given visual format overrides that implied by the context UI marker |
140 | | * or set earlier using withFormat. |
141 | | * If the message is not markup-aware, |
142 | | * this is same as toString without arguments. |
143 | | * |
144 | | * \a format the target visual format |
145 | | * |
146 | | * Returns finalized translation |
147 | | */ |
148 | | Q_REQUIRED_RESULT QString toString(Kuit::VisualFormat format) const; |
149 | | |
150 | | /*! |
151 | | * Indicate to look for translation only in given languages. |
152 | | * |
153 | | * \a languages list of language codes (by decreasing priority) |
154 | | * |
155 | | * Returns updated KLocalizedString |
156 | | */ |
157 | | Q_REQUIRED_RESULT KLocalizedString withLanguages(const QStringList &languages) const; |
158 | | |
159 | | /*! |
160 | | * Indicate to look for translation in the given domain. |
161 | | * |
162 | | * \a domain the translation domain |
163 | | * Returns updated KLocalizedString |
164 | | */ |
165 | | Q_REQUIRED_RESULT KLocalizedString withDomain(const char *domain) const; |
166 | | |
167 | | /*! |
168 | | * Indicate to resolve KUIT markup into given visual format. |
169 | | * |
170 | | * If the message is not markup-aware, this has no effect. |
171 | | * |
172 | | * \a format the target visual format |
173 | | * |
174 | | * Returns updated KLocalizedString |
175 | | */ |
176 | | Q_REQUIRED_RESULT KLocalizedString withFormat(Kuit::VisualFormat format) const; |
177 | | |
178 | | /*! |
179 | | * Substitute an int argument into the message. |
180 | | * |
181 | | * \a a the argument |
182 | | * |
183 | | * \a fieldWidth width of the formatted field, padded by spaces. |
184 | | * Positive value aligns right, negative aligns left |
185 | | * |
186 | | * \a base the radix used to represent the number as a string. |
187 | | * Valid values range from 2 to 36 |
188 | | * |
189 | | * \a fillChar the character used to fill up the empty places when |
190 | | * field width is greater than argument width |
191 | | * |
192 | | * Returns updated KLocalizedString |
193 | | */ |
194 | | Q_REQUIRED_RESULT KLocalizedString subs(int a, int fieldWidth = 0, int base = 10, QChar fillChar = QLatin1Char(' ')) const; |
195 | | |
196 | | /*! |
197 | | * Substitute an unsigned int argument into the message. |
198 | | * |
199 | | * \a a the argument |
200 | | * |
201 | | * \a fieldWidth width of the formatted field, padded by spaces. |
202 | | * Positive value aligns right, negative aligns left |
203 | | * |
204 | | * \a base the radix used to represent the number as a string. |
205 | | * Valid values range from 2 to 36 |
206 | | * |
207 | | * \a fillChar the character used to fill up the empty places when |
208 | | * field width is greater than argument width |
209 | | * |
210 | | * Returns updated KLocalizedString |
211 | | */ |
212 | | Q_REQUIRED_RESULT KLocalizedString subs(uint a, int fieldWidth = 0, int base = 10, QChar fillChar = QLatin1Char(' ')) const; |
213 | | |
214 | | /*! |
215 | | * Substitute a long argument into the message. |
216 | | * |
217 | | * \a a the argument |
218 | | * |
219 | | * \a fieldWidth width of the formatted field, padded by spaces. |
220 | | * Positive value aligns right, negative aligns left |
221 | | * |
222 | | * \a base the radix used to represent the number as a string. |
223 | | * Valid values range from 2 to 36 |
224 | | * |
225 | | * \a fillChar the character used to fill up the empty places when |
226 | | * field width is greater than argument width |
227 | | * |
228 | | * Returns updated KLocalizedString |
229 | | */ |
230 | | Q_REQUIRED_RESULT KLocalizedString subs(long a, int fieldWidth = 0, int base = 10, QChar fillChar = QLatin1Char(' ')) const; |
231 | | |
232 | | /*! |
233 | | * Substitute an unsigned long argument into the message. |
234 | | * |
235 | | * \a a the argument |
236 | | * |
237 | | * \a fieldWidth width of the formatted field, padded by spaces. |
238 | | * Positive value aligns right, negative aligns left |
239 | | * |
240 | | * \a base the radix used to represent the number as a string. |
241 | | * Valid values range from 2 to 36 |
242 | | * |
243 | | * \a fillChar the character used to fill up the empty places when |
244 | | * field width is greater than argument width |
245 | | * |
246 | | * Returns updated KLocalizedString |
247 | | */ |
248 | | Q_REQUIRED_RESULT KLocalizedString subs(ulong a, int fieldWidth = 0, int base = 10, QChar fillChar = QLatin1Char(' ')) const; |
249 | | |
250 | | /*! |
251 | | * Substitute a long long argument into the message. |
252 | | * |
253 | | * \a a the argument |
254 | | * |
255 | | * \a fieldWidth width of the formatted field, padded by spaces. |
256 | | * Positive value aligns right, negative aligns left |
257 | | * |
258 | | * \a base the radix used to represent the number as a string. |
259 | | * Valid values range from 2 to 36 |
260 | | * |
261 | | * \a fillChar the character used to fill up the empty places when |
262 | | * field width is greater than argument width |
263 | | * |
264 | | * Returns updated KLocalizedString |
265 | | */ |
266 | | Q_REQUIRED_RESULT KLocalizedString subs(qlonglong a, int fieldWidth = 0, int base = 10, QChar fillChar = QLatin1Char(' ')) const; |
267 | | |
268 | | /*! |
269 | | * Substitute an unsigned long long argument into the message. |
270 | | * |
271 | | * \a a the argument |
272 | | * |
273 | | * \a fieldWidth width of the formatted field, padded by spaces. |
274 | | * Positive value aligns right, negative aligns left |
275 | | * |
276 | | * \a base the radix used to represent the number as a string. |
277 | | * Valid values range from 2 to 36 |
278 | | * |
279 | | * \a fillChar the character used to fill up the empty places when |
280 | | * field width is greater than argument width |
281 | | * |
282 | | * Returns updated KLocalizedString |
283 | | */ |
284 | | Q_REQUIRED_RESULT KLocalizedString subs(qulonglong a, int fieldWidth = 0, int base = 10, QChar fillChar = QLatin1Char(' ')) const; |
285 | | |
286 | | /*! |
287 | | * Substitute a double argument into the message. |
288 | | * |
289 | | * \a a the argument |
290 | | * |
291 | | * \a fieldWidth width of the formatted field, padded by spaces. |
292 | | * Positive value aligns right, negative aligns left |
293 | | * |
294 | | * \a format type of floating point formatting, like in QString::arg |
295 | | * |
296 | | * \a precision number of digits after the decimal separator |
297 | | * |
298 | | * \a fillChar the character used to fill up the empty places when |
299 | | * field width is greater than argument width |
300 | | * |
301 | | * Returns updated KLocalizedString |
302 | | */ |
303 | | Q_REQUIRED_RESULT KLocalizedString subs(double a, int fieldWidth = 0, char format = 'g', int precision = -1, QChar fillChar = QLatin1Char(' ')) const; |
304 | | |
305 | | /*! |
306 | | * Substitute a QChar argument into the message. |
307 | | * |
308 | | * \a a the argument |
309 | | * |
310 | | * \a fieldWidth width of the formatted field, padded by spaces. |
311 | | * Positive value aligns right, negative aligns left |
312 | | * |
313 | | * \a fillChar the character used to fill up the empty places when |
314 | | * field width is greater than argument width |
315 | | * |
316 | | * Returns updated KLocalizedString |
317 | | */ |
318 | | Q_REQUIRED_RESULT KLocalizedString subs(QChar a, int fieldWidth = 0, QChar fillChar = QLatin1Char(' ')) const; |
319 | | |
320 | | /*! |
321 | | * Substitute a QString argument into the message. |
322 | | * |
323 | | * \a a the argument |
324 | | * |
325 | | * \a fieldWidth width of the formatted field, padded by spaces. |
326 | | * Positive value aligns right, negative aligns left |
327 | | * |
328 | | * \a fillChar the character used to fill up the empty places when |
329 | | * field width is greater than argument width |
330 | | * |
331 | | * Returns updated KLocalizedString |
332 | | */ |
333 | | Q_REQUIRED_RESULT KLocalizedString subs(const QString &a, int fieldWidth = 0, QChar fillChar = QLatin1Char(' ')) const; |
334 | | |
335 | | /*! |
336 | | * Substitute another KLocalizedString into the message. |
337 | | * |
338 | | * \a a the argument |
339 | | * |
340 | | * \a fieldWidth width of the formatted field, padded by spaces. |
341 | | * Positive value aligns right, negative aligns left |
342 | | * |
343 | | * \a fillChar the character used to fill up the empty places when |
344 | | * field width is greater than argument width |
345 | | * |
346 | | * Returns updated KLocalizedString |
347 | | */ |
348 | | Q_REQUIRED_RESULT KLocalizedString subs(const KLocalizedString &a, int fieldWidth = 0, QChar fillChar = QLatin1Char(' ')) const; |
349 | | |
350 | | /*! |
351 | | * Add dynamic context to the message. |
352 | | * |
353 | | * See dyn_ctxt for use cases. |
354 | | * |
355 | | * \a key context key |
356 | | * |
357 | | * \a value context value |
358 | | * |
359 | | * Returns updated KLocalizedString |
360 | | */ |
361 | | Q_REQUIRED_RESULT KLocalizedString inContext(const QString &key, const QString &value) const; |
362 | | |
363 | | /*! |
364 | | * Relax matching between placeholders and arguments. |
365 | | * |
366 | | * Normally the placeholders should start from %1 and have no gaps, |
367 | | * and on finalization there must be exactly as many arguments |
368 | | * supplied through subs methods as there are unique plaecholders. |
369 | | * If this is not satisfied, in debug mode warnings are printed |
370 | | * and the finalized string may contain error marks. |
371 | | * |
372 | | * This method relaxes the placeholder-argument matching, |
373 | | * such that there must only be an argument available for |
374 | | * every present unique placeholder (taking placeholder numbers |
375 | | * to be 1-based indices into the argument list). |
376 | | * This can come useful in some situations. |
377 | | * |
378 | | * Returns updated KLocalizedString |
379 | | */ |
380 | | Q_REQUIRED_RESULT KLocalizedString relaxSubs() const; |
381 | | |
382 | | /*! |
383 | | * Do not resolve KUIT markup. |
384 | | * |
385 | | * If the message is markup-aware |
386 | | * (constructed by one of *xi18n* calls), |
387 | | * this function can be used to make it non-markup-aware. |
388 | | * This may be useful for debugging markup. |
389 | | * |
390 | | * Returns updated KLocalizedString |
391 | | */ |
392 | | Q_REQUIRED_RESULT KLocalizedString ignoreMarkup() const; |
393 | | |
394 | | /*! |
395 | | * Returns the untranslated text. |
396 | | * |
397 | | * \since 5.64 |
398 | | */ |
399 | | Q_REQUIRED_RESULT QByteArray untranslatedText() const; |
400 | | |
401 | | /*! |
402 | | * Set the given domain as application's main domain. |
403 | | * |
404 | | * This function must be called in applications, in order to have |
405 | | * any translations at all. It should never be called in libraries. |
406 | | * This allows to check whether the application is translated |
407 | | * into a given language, so that if it is not, translations from |
408 | | * underlying libraries will not appear even if they are translated. |
409 | | * This prevents mixing of translated and untranslated text |
410 | | * in the user interface. |
411 | | * |
412 | | * This function should be called right after creating the instance |
413 | | * of QCoreApplication or one of its subclasses. At that time the locale |
414 | | * setup has been made, including what is hooked into the |
415 | | * QCoreApplication startup, like KXMLGUI's language switching support. |
416 | | * So the initialisation done by this function sees all the data it should. |
417 | | * |
418 | | * \a domain the translation domain of the application |
419 | | */ |
420 | | static void setApplicationDomain(const QByteArray &domain); |
421 | | |
422 | | /*! |
423 | | * Get the application's main translation domain. |
424 | | * |
425 | | * Returns the domain set by setApplicationDomain. |
426 | | */ |
427 | | static QByteArray applicationDomain(); |
428 | | |
429 | | /*! |
430 | | * Get the languages for which translations will be made. |
431 | | * |
432 | | * Returned languages are ordered with decreasing priority. |
433 | | * |
434 | | * Returns languages ordered list of language codes |
435 | | * \sa setLanguages |
436 | | * \sa clearLanguages |
437 | | * |
438 | | * \since 5.20.0 |
439 | | */ |
440 | | static QStringList languages(); |
441 | | |
442 | | /*! |
443 | | * Set the languages for which translations will be made. |
444 | | * |
445 | | * This overrides the languages provided by the locale. |
446 | | * Languages should be ordered with decreasing priority. |
447 | | * |
448 | | * \a languages ordered list of language codes |
449 | | * |
450 | | * \sa setLocale |
451 | | * \sa clearLanguages |
452 | | * \sa languages |
453 | | */ |
454 | | static void setLanguages(const QStringList &languages); |
455 | | |
456 | | /*! |
457 | | * Clear override languages. |
458 | | * |
459 | | * This clears the override languages, going back to those |
460 | | * provided by the locale. |
461 | | * |
462 | | * \sa setLanguages |
463 | | * \sa languages |
464 | | */ |
465 | | static void clearLanguages(); |
466 | | |
467 | | /*! |
468 | | * Check whether the translation catalog file in the given language |
469 | | * for the set application translation domain exists. |
470 | | * |
471 | | * \a language the language code to check |
472 | | * |
473 | | * Returns \c true if the translation catalog for \a language exits, |
474 | | * \c false otherwise |
475 | | * \sa setApplicationDomain |
476 | | */ |
477 | | static bool isApplicationTranslatedInto(const QString &language); |
478 | | |
479 | | /*! |
480 | | * \since 5.0 |
481 | | * |
482 | | * Get the languages for which there exists the translation catalog file |
483 | | * for the set application translation domain. |
484 | | * |
485 | | * The application domain is set by setApplicationDomain. |
486 | | * If the application domain was not set, empty set is returned. |
487 | | * If the application domain was set, the language set will always |
488 | | * contain at least the source code language (en_US). |
489 | | * |
490 | | * Returns set of language codes for existing translation catalogs |
491 | | * \sa setApplicationDomain |
492 | | */ |
493 | | static QSet<QString> availableApplicationTranslations(); |
494 | | |
495 | | /*! |
496 | | * \since 5.0 |
497 | | * |
498 | | * Get the languages for which a translation catalog file |
499 | | * for the passed translation domain exists. |
500 | | * |
501 | | * If the translation domain was not specified in the |
502 | | * domain parameter an empty set is returned. |
503 | | * |
504 | | * If the application domain was set, the language set will always |
505 | | * contain at least the source code language (en_US). |
506 | | * |
507 | | * \a domain query for translations of a specific domain, if an empty |
508 | | * QByteArray is passed, an empty set will be returned |
509 | | * |
510 | | * Returns set of language codes for existing translation catalogs |
511 | | * \sa setApplicationDomain |
512 | | * \sa availableApplicationTranslations |
513 | | */ |
514 | | static QSet<QString> availableDomainTranslations(const QByteArray &domain); |
515 | | |
516 | | /*! |
517 | | * Load locales for a domain from a specific location |
518 | | * This is useful for resources which have their translation files |
519 | | * outside of the usual $XDG_DATA_DIRS/locales location |
520 | | * |
521 | | * \a domain the domain to load resources from |
522 | | * |
523 | | * \a path the full file path to the locale directory |
524 | | */ |
525 | | static void addDomainLocaleDir(const QByteArray &domain, const QString &path); |
526 | | |
527 | | /*! |
528 | | * Find a path to the localized file for the given original path. |
529 | | * |
530 | | * This is intended mainly for non-text resources (images, sounds, etc). |
531 | | * Text resources should be handled in more specific ways. |
532 | | * |
533 | | * Possible localized paths are checked in turn by priority of set |
534 | | * languages, in form of <dirname>/l10n/<lang>/<basename>, |
535 | | * where <dirname> and <basename> are those of |
536 | | * the original path, and <lang> is the language code. |
537 | | * |
538 | | * \a filePath path to the original file |
539 | | * |
540 | | * Returns path to the localized file if found, original path otherwise |
541 | | */ |
542 | | Q_REQUIRED_RESULT static QString localizedFilePath(const QString &filePath); |
543 | | |
544 | | /*! |
545 | | * Remove accelerator marker from a UI text label. |
546 | | * |
547 | | * Accelerator marker is not always a plain ampersand (&), |
548 | | * so it is not enough to just remove it by QString::remove. |
549 | | * The label may contain escaped markers ("&&") which must be resolved |
550 | | * and skipped, as well as CJK-style markers ("Foo (&F)") where |
551 | | * the whole parenthesis construct should be removed. |
552 | | * Therefore always use this function to remove accelerator marker |
553 | | * from UI labels. |
554 | | * |
555 | | * \a label UI label which may contain an accelerator marker |
556 | | * |
557 | | * Returns label without the accelerator marker |
558 | | */ |
559 | | Q_REQUIRED_RESULT static QString removeAcceleratorMarker(const QString &label); |
560 | | |
561 | | private: |
562 | | // exported because called from inline KLazyLocalizedString::operator KLocalizedString() |
563 | | KLocalizedString(const char *domain, const char *context, const char *text, const char *plural, bool markupAware); |
564 | | |
565 | | private: |
566 | | // intentionally not a unique_ptr as this file gets included a lot and using a unique_ptr |
567 | | // results in too many template instantiations |
568 | | KLocalizedStringPrivate *const d; |
569 | | }; |
570 | | |
571 | | // Do not document every multi-argument i18n* call separately, |
572 | | // but provide special quasi-calls that only qdoc sees. |
573 | | // Placed in front of ki18n* calls, because i18n* are more basic. |
574 | | #ifdef Q_QDOC |
575 | | |
576 | | /*! |
577 | | * Translate a string and substitute any arguments. |
578 | | * |
579 | | * \a text string to translate |
580 | | * |
581 | | * \a arg arguments to insert (0 to 9), |
582 | | * admissible types according to KLocalizedString::subs methods |
583 | | * |
584 | | * Returns translated string |
585 | | * |
586 | | * \relates KLocalizedString |
587 | | */ |
588 | | QString i18n(const char *text, const TYPE &arg...); |
589 | | |
590 | | /*! |
591 | | * Translate a string with context and substitute any arguments. |
592 | | * |
593 | | * \a context context of the string |
594 | | * |
595 | | * \a text string to translate |
596 | | * |
597 | | * \a arg arguments to insert (0 to 9), |
598 | | * admissible types according to KLocalizedString::subs methods |
599 | | * |
600 | | * Returns translated string |
601 | | * |
602 | | * \relates KLocalizedString |
603 | | */ |
604 | | QString i18nc(const char *context, const char *text, const TYPE &arg...); |
605 | | |
606 | | /*! |
607 | | * Translate a string with plural and substitute any arguments. |
608 | | * |
609 | | * \a singular singular form of the string to translate |
610 | | * |
611 | | * \a plural plural form of the string to translate |
612 | | * |
613 | | * \a arg arguments to insert (0 to 9), |
614 | | * admissible types according to KLocalizedString::subs methods |
615 | | * |
616 | | * Returns translated string |
617 | | * |
618 | | * \relates KLocalizedString |
619 | | */ |
620 | | QString i18np(const char *singular, const char *plural, const TYPE &arg...); |
621 | | |
622 | | /*! |
623 | | * Translate a string with context and plural and substitute any arguments. |
624 | | * |
625 | | * \a context context of the string |
626 | | * |
627 | | * \a singular singular form of the string to translate |
628 | | * |
629 | | * \a plural plural form of the string to translate |
630 | | * |
631 | | * \a arg arguments to insert (0 to 9), |
632 | | * admissible types according to KLocalizedString::subs methods |
633 | | * |
634 | | * Returns translated string |
635 | | * |
636 | | * \relates KLocalizedString |
637 | | */ |
638 | | QString i18ncp(const char *context, const char *singular, const char *plural, const TYPE &arg...); |
639 | | |
640 | | /*! |
641 | | * Translate a string from domain and substitute any arguments. |
642 | | * |
643 | | * \a domain domain in which to look for translations |
644 | | * |
645 | | * \a text string to translate |
646 | | * |
647 | | * \a arg arguments to insert (0 to 9), |
648 | | * admissible types according to KLocalizedString::subs methods |
649 | | * |
650 | | * Returns translated string |
651 | | * |
652 | | * \relates KLocalizedString |
653 | | */ |
654 | | QString i18nd(const char *domain, const char *text, const TYPE &arg...); |
655 | | |
656 | | /*! |
657 | | * Translate a string from domain with context and substitute any arguments. |
658 | | * |
659 | | * \a domain domain in which to look for translations |
660 | | * |
661 | | * \a context context of the string |
662 | | * |
663 | | * \a text string to translate |
664 | | * |
665 | | * \a arg arguments to insert (0 to 9), |
666 | | * admissible types according to KLocalizedString::subs methods |
667 | | * |
668 | | * Returns translated string |
669 | | * |
670 | | * \relates KLocalizedString |
671 | | */ |
672 | | QString i18ndc(const char *domain, const char *context, const char *text, const TYPE &arg...); |
673 | | |
674 | | /*! |
675 | | * Translate a string from domain with plural and substitute any arguments. |
676 | | * |
677 | | * \a domain domain in which to look for translations |
678 | | * |
679 | | * \a singular singular form of the string to translate |
680 | | * |
681 | | * \a plural plural form of the string to translate |
682 | | * |
683 | | * \a arg arguments to insert (0 to 9), |
684 | | * admissible types according to KLocalizedString::subs methods |
685 | | * |
686 | | * Returns translated string |
687 | | * |
688 | | * \relates KLocalizedString |
689 | | */ |
690 | | QString i18ndp(const char *domain, const char *singular, const char *plural, const TYPE &arg...); |
691 | | |
692 | | /*! |
693 | | * Translate a string from domain with context and plural |
694 | | * and substitute any arguments. |
695 | | * |
696 | | * \a domain domain in which to look for translations |
697 | | * |
698 | | * \a context context of the string |
699 | | * |
700 | | * \a singular singular form of the string to translate |
701 | | * |
702 | | * \a plural plural form of the string to translate |
703 | | * |
704 | | * \a arg arguments to insert (0 to 9), |
705 | | * admissible types according to KLocalizedString::subs methods |
706 | | * |
707 | | * Returns translated string |
708 | | * |
709 | | * \relates KLocalizedString |
710 | | */ |
711 | | QString i18ndcp(const char *domain, const char *context, const char *singular, const char *plural, const TYPE &arg...); |
712 | | |
713 | | /*! |
714 | | * Translate a markup-aware string and substitute any arguments. |
715 | | * |
716 | | * \a text string to translate |
717 | | * |
718 | | * \a arg arguments to insert (0 to 9), |
719 | | * admissible types according to KLocalizedString::subs methods |
720 | | * |
721 | | * Returns translated string |
722 | | * |
723 | | * \relates KLocalizedString |
724 | | */ |
725 | | QString xi18n(const char *text, const TYPE &arg...); |
726 | | |
727 | | /*! |
728 | | * Translate a markup-aware string with context and substitute any arguments. |
729 | | * |
730 | | * \a context context of the string |
731 | | * |
732 | | * \a text string to translate |
733 | | * |
734 | | * \a arg arguments to insert (0 to 9), |
735 | | * admissible types according to KLocalizedString::subs methods |
736 | | * |
737 | | * Returns translated string |
738 | | * |
739 | | * \relates KLocalizedString |
740 | | */ |
741 | | QString xi18nc(const char *context, const char *text, const TYPE &arg...); |
742 | | |
743 | | /*! |
744 | | * Translate a markup-aware string with plural and substitute any arguments. |
745 | | * |
746 | | * \a singular singular form of the string to translate |
747 | | * |
748 | | * \a plural plural form of the string to translate |
749 | | * |
750 | | * \a arg arguments to insert (0 to 9), |
751 | | * admissible types according to KLocalizedString::subs methods |
752 | | * |
753 | | * Returns translated string |
754 | | * |
755 | | * \relates KLocalizedString |
756 | | */ |
757 | | QString xi18np(const char *singular, const char *plural, const TYPE &arg...); |
758 | | |
759 | | /*! |
760 | | * Translate a markup-aware string with context and plural |
761 | | * and substitute any arguments. |
762 | | * |
763 | | * \a context context of the string |
764 | | * |
765 | | * \a singular singular form of the string to translate |
766 | | * |
767 | | * \a plural plural form of the string to translate |
768 | | * |
769 | | * \a arg arguments to insert (0 to 9), |
770 | | * admissible types according to KLocalizedString::subs methods |
771 | | * |
772 | | * Returns translated string |
773 | | * |
774 | | * \relates KLocalizedString |
775 | | */ |
776 | | QString xi18ncp(const char *context, const char *singular, const char *plural, const TYPE &arg...); |
777 | | |
778 | | /*! |
779 | | * Translate a markup-aware string from domain and substitute any arguments. |
780 | | * |
781 | | * \a domain domain in which to look for translations |
782 | | * |
783 | | * \a text string to translate |
784 | | * |
785 | | * \a arg arguments to insert (0 to 9), |
786 | | * admissible types according to KLocalizedString::subs methods |
787 | | * |
788 | | * Returns translated string |
789 | | * |
790 | | * \relates KLocalizedString |
791 | | */ |
792 | | QString xi18nd(const char *domain, const char *text, const TYPE &arg...); |
793 | | |
794 | | /*! |
795 | | * Translate a markup-aware string from domain with context |
796 | | * and substitute any arguments. |
797 | | * |
798 | | * \a domain domain in which to look for translations |
799 | | * |
800 | | * \a context context of the string |
801 | | * |
802 | | * \a text string to translate |
803 | | * |
804 | | * \a arg arguments to insert (0 to 9), |
805 | | * admissible types according to KLocalizedString::subs methods |
806 | | * |
807 | | * Returns translated string |
808 | | * |
809 | | * \relates KLocalizedString |
810 | | */ |
811 | | QString xi18ndc(const char *domain, const char *context, const char *text, const TYPE &arg...); |
812 | | |
813 | | /*! |
814 | | * Translate a markup-aware string from domain with plural |
815 | | * and substitute any arguments. |
816 | | * |
817 | | * \a domain domain in which to look for translations |
818 | | * |
819 | | * \a singular singular form of the string to translate |
820 | | * |
821 | | * \a plural plural form of the string to translate |
822 | | * |
823 | | * \a arg arguments to insert (0 to 9), |
824 | | * admissible types according to KLocalizedString::subs methods |
825 | | * |
826 | | * Returns translated string |
827 | | * |
828 | | * \relates KLocalizedString |
829 | | */ |
830 | | QString xi18ndp(const char *domain, const char *singular, const char *plural, const TYPE &arg...); |
831 | | |
832 | | /*! |
833 | | * Translate a markup-aware string from domain with context and plural |
834 | | * and substitute any arguments. |
835 | | * |
836 | | * \a domain domain in which to look for translations |
837 | | * |
838 | | * \a context context of the string |
839 | | * |
840 | | * \a singular singular form of the string to translate |
841 | | * |
842 | | * \a plural plural form of the string to translate |
843 | | * |
844 | | * \a arg arguments to insert (0 to 9), |
845 | | * admissible types according to KLocalizedString::subs methods |
846 | | * |
847 | | * Returns translated string |
848 | | * |
849 | | * \relates KLocalizedString |
850 | | */ |
851 | | QString xi18ndcp(const char *domain, const char *context, const char *singular, const char *plural, const TYPE &arg...); |
852 | | |
853 | | #endif // Q_QDOC |
854 | | |
855 | | /*! |
856 | | * Create non-finalized translated string. |
857 | | * |
858 | | * \a text string to translate |
859 | | * |
860 | | * Returns non-finalized translated string |
861 | | * |
862 | | * \relates KLocalizedString |
863 | | */ |
864 | | KLocalizedString KI18N_EXPORT ki18n(const char *text); |
865 | | |
866 | | /*! |
867 | | * Create non-finalized translated string with context. |
868 | | * |
869 | | * \a context context of the string |
870 | | * |
871 | | * \a text string to translate |
872 | | * |
873 | | * Returns non-finalized translated string |
874 | | * |
875 | | * \relates KLocalizedString |
876 | | */ |
877 | | KLocalizedString KI18N_EXPORT ki18nc(const char *context, const char *text); |
878 | | |
879 | | /*! |
880 | | * Create non-finalized translated string with plural. |
881 | | * |
882 | | * \a singular singular form of the string to translate |
883 | | * |
884 | | * \a plural plural form of the string to translate |
885 | | * |
886 | | * Returns non-finalized translated string |
887 | | * |
888 | | * \relates KLocalizedString |
889 | | */ |
890 | | KLocalizedString KI18N_EXPORT ki18np(const char *singular, const char *plural); |
891 | | |
892 | | /*! |
893 | | * Create non-finalized translated string with context and plural. |
894 | | * |
895 | | * \a context context of the string |
896 | | * |
897 | | * \a singular singular form of the string to translate |
898 | | * |
899 | | * \a plural plural form of the string to translate |
900 | | * |
901 | | * Returns non-finalized translated string |
902 | | * |
903 | | * \relates KLocalizedString |
904 | | */ |
905 | | KLocalizedString KI18N_EXPORT ki18ncp(const char *context, const char *singular, const char *plural); |
906 | | |
907 | | /*! |
908 | | * Create non-finalized translated string from domain. |
909 | | * |
910 | | * \a domain domain in which to look for translations |
911 | | * |
912 | | * \a text string to translate |
913 | | * |
914 | | * Returns non-finalized translated string |
915 | | * |
916 | | * \relates KLocalizedString |
917 | | */ |
918 | | KLocalizedString KI18N_EXPORT ki18nd(const char *domain, const char *text); |
919 | | |
920 | | /*! |
921 | | * Create non-finalized translated string from domain with context. |
922 | | * |
923 | | * \a domain domain in which to look for translations |
924 | | * |
925 | | * \a context context of the string |
926 | | * |
927 | | * \a text string to translate |
928 | | * |
929 | | * Returns non-finalized translated string |
930 | | * |
931 | | * \relates KLocalizedString |
932 | | */ |
933 | | KLocalizedString KI18N_EXPORT ki18ndc(const char *domain, const char *context, const char *text); |
934 | | |
935 | | /*! |
936 | | * Create non-finalized translated string from domain with plural. |
937 | | * |
938 | | * \a domain domain in which to look for translations |
939 | | * |
940 | | * \a singular singular form of the string to translate |
941 | | * |
942 | | * \a plural plural form of the string to translate |
943 | | * |
944 | | * Returns non-finalized translated string |
945 | | * |
946 | | * \relates KLocalizedString |
947 | | */ |
948 | | KLocalizedString KI18N_EXPORT ki18ndp(const char *domain, const char *singular, const char *plural); |
949 | | |
950 | | /*! |
951 | | * Create non-finalized translated string from domain with context and plural. |
952 | | * |
953 | | * \a domain domain in which to look for translations |
954 | | * |
955 | | * \a context context of the string |
956 | | * |
957 | | * \a singular singular form of the string to translate |
958 | | * |
959 | | * \a plural plural form of the string to translate |
960 | | * |
961 | | * Returns non-finalized translated string |
962 | | * |
963 | | * \relates KLocalizedString |
964 | | */ |
965 | | KLocalizedString KI18N_EXPORT ki18ndcp(const char *domain, const char *context, const char *singular, const char *plural); |
966 | | |
967 | | /*! |
968 | | * Create non-finalized markup-aware translated string. |
969 | | * |
970 | | * \a text string to translate |
971 | | * |
972 | | * Returns non-finalized translated string |
973 | | * |
974 | | * \relates KLocalizedString |
975 | | */ |
976 | | KLocalizedString KI18N_EXPORT kxi18n(const char *text); |
977 | | |
978 | | /*! |
979 | | * Create non-finalized markup-aware translated string with context. |
980 | | * |
981 | | * \a context context of the string |
982 | | * |
983 | | * \a text string to translate |
984 | | * |
985 | | * Returns non-finalized translated string |
986 | | * |
987 | | * \relates KLocalizedString |
988 | | */ |
989 | | KLocalizedString KI18N_EXPORT kxi18nc(const char *context, const char *text); |
990 | | |
991 | | /*! |
992 | | * Create non-finalized markup-aware translated string with plural. |
993 | | * |
994 | | * \a singular singular form of the string to translate |
995 | | * |
996 | | * \a plural plural form of the string to translate |
997 | | * |
998 | | * Returns non-finalized translated string |
999 | | * |
1000 | | * \relates KLocalizedString |
1001 | | */ |
1002 | | KLocalizedString KI18N_EXPORT kxi18np(const char *singular, const char *plural); |
1003 | | |
1004 | | /*! |
1005 | | * Create non-finalized markup-aware translated string. |
1006 | | * with context and plural. |
1007 | | * |
1008 | | * \a context context of the string |
1009 | | * |
1010 | | * \a singular singular form of the string to translate |
1011 | | * |
1012 | | * \a plural plural form of the string to translate |
1013 | | * |
1014 | | * Returns non-finalized translated string |
1015 | | * |
1016 | | * \relates KLocalizedString |
1017 | | */ |
1018 | | KLocalizedString KI18N_EXPORT kxi18ncp(const char *context, const char *singular, const char *plural); |
1019 | | |
1020 | | /*! |
1021 | | * Create non-finalized markup-aware translated string from domain. |
1022 | | * |
1023 | | * \a domain domain in which to look for translations |
1024 | | * |
1025 | | * \a text string to translate |
1026 | | * |
1027 | | * Returns non-finalized translated string |
1028 | | * |
1029 | | * \relates KLocalizedString |
1030 | | */ |
1031 | | KLocalizedString KI18N_EXPORT kxi18nd(const char *domain, const char *text); |
1032 | | |
1033 | | /*! |
1034 | | * Create non-finalized markup-aware translated string from domain with context. |
1035 | | * |
1036 | | * \a domain domain in which to look for translations |
1037 | | * |
1038 | | * \a context context of the string |
1039 | | * |
1040 | | * \a text string to translate |
1041 | | * |
1042 | | * Returns non-finalized translated string |
1043 | | * |
1044 | | * \relates KLocalizedString |
1045 | | */ |
1046 | | KLocalizedString KI18N_EXPORT kxi18ndc(const char *domain, const char *context, const char *text); |
1047 | | |
1048 | | /*! |
1049 | | * Create non-finalized markup-aware translated string from domain with plural. |
1050 | | * |
1051 | | * \a domain domain in which to look for translations |
1052 | | * |
1053 | | * \a singular singular form of the string to translate |
1054 | | * |
1055 | | * \a plural plural form of the string to translate |
1056 | | * |
1057 | | * Returns non-finalized translated string |
1058 | | * |
1059 | | * \relates KLocalizedString |
1060 | | */ |
1061 | | KLocalizedString KI18N_EXPORT kxi18ndp(const char *domain, const char *singular, const char *plural); |
1062 | | |
1063 | | /*! |
1064 | | * Create non-finalized markup-aware translated string from domain |
1065 | | * with context and plural. |
1066 | | * |
1067 | | * \a domain domain in which to look for translations |
1068 | | * |
1069 | | * \a context context of the string |
1070 | | * |
1071 | | * \a singular singular form of the string to translate |
1072 | | * |
1073 | | * \a plural plural form of the string to translate |
1074 | | * |
1075 | | * Returns non-finalized translated string |
1076 | | * |
1077 | | * \relates KLocalizedString |
1078 | | */ |
1079 | | KLocalizedString KI18N_EXPORT kxi18ndcp(const char *domain, const char *context, const char *singular, const char *plural); |
1080 | | |
1081 | | /*! |
1082 | | * Redirect Qt's uic-generated translation calls to Ki18n. |
1083 | | * |
1084 | | * Use -tr tr2i18n option to uic to have it redirect calls. |
1085 | | * |
1086 | | * \a text string to translate |
1087 | | * |
1088 | | * \a comment Qt equivalent of disambiguation context |
1089 | | * |
1090 | | * Returns translated string |
1091 | | * |
1092 | | * \relates KLocalizedString |
1093 | | */ |
1094 | | inline QString tr2i18n(const char *text, const char *comment = nullptr) |
1095 | 0 | { |
1096 | 0 | if (comment && comment[0] && text && text[0]) { |
1097 | 0 | return ki18nc(comment, text).toString(); |
1098 | 0 | } else if (text && text[0]) { |
1099 | 0 | return ki18n(text).toString(); |
1100 | 0 | } else { |
1101 | 0 | return QString(); |
1102 | 0 | } |
1103 | 0 | } |
1104 | | |
1105 | | /*! |
1106 | | * Like tr2i18n, but look for translation in a specific domain. |
1107 | | * |
1108 | | * Use -tr tr2i18nd option to uic to have it redirect calls. |
1109 | | * |
1110 | | * \a domain domain in which to look for translations |
1111 | | * |
1112 | | * \a text string to translate |
1113 | | * |
1114 | | * \a comment Qt equivalent of disambiguation context |
1115 | | * |
1116 | | * Returns translated string |
1117 | | * |
1118 | | * \relates KLocalizedString |
1119 | | */ |
1120 | | inline QString tr2i18nd(const char *domain, const char *text, const char *comment = nullptr) |
1121 | 0 | { |
1122 | 0 | if (comment && comment[0] && text && text[0]) { |
1123 | 0 | return ki18ndc(domain, comment, text).toString(); |
1124 | 0 | } else if (text && text[0]) { |
1125 | 0 | return ki18nd(domain, text).toString(); |
1126 | 0 | } else { |
1127 | 0 | return QString(); |
1128 | 0 | } |
1129 | 0 | } |
1130 | | |
1131 | | /*! |
1132 | | * Like tr2i18n, but when UI strings are KUIT markup-aware. |
1133 | | * |
1134 | | * Use -tr tr2xi18n option to uic to have it redirect calls. |
1135 | | * |
1136 | | * \a text markup-aware string to translate |
1137 | | * |
1138 | | * \a comment Qt equivalent of disambiguation context |
1139 | | * |
1140 | | * Returns translated string |
1141 | | * |
1142 | | * \relates KLocalizedString |
1143 | | */ |
1144 | | inline QString tr2xi18n(const char *text, const char *comment = nullptr) |
1145 | 0 | { |
1146 | 0 | if (comment && comment[0] && text && text[0]) { |
1147 | 0 | return kxi18nc(comment, text).toString(); |
1148 | 0 | } else if (text && text[0]) { |
1149 | 0 | return kxi18n(text).toString(); |
1150 | 0 | } else { |
1151 | 0 | return QString(); |
1152 | 0 | } |
1153 | 0 | } |
1154 | | |
1155 | | /*! |
1156 | | * Like tr2xi18n, but look for translation in a specific domain. |
1157 | | * |
1158 | | * Use -tr tr2xi18nd option to uic to have it redirect calls. |
1159 | | * |
1160 | | * \a domain domain in which to look for translations |
1161 | | * |
1162 | | * \a text markup-aware string to translate |
1163 | | * |
1164 | | * \a comment Qt equivalent of disambiguation context |
1165 | | * |
1166 | | * Returns translated string |
1167 | | * |
1168 | | * \relates KLocalizedString |
1169 | | */ |
1170 | | inline QString tr2xi18nd(const char *domain, const char *text, const char *comment = nullptr) |
1171 | 0 | { |
1172 | 0 | if (comment && comment[0] && text && text[0]) { |
1173 | 0 | return kxi18ndc(domain, comment, text).toString(); |
1174 | 0 | } else if (text && text[0]) { |
1175 | 0 | return kxi18nd(domain, text).toString(); |
1176 | 0 | } else { |
1177 | 0 | return QString(); |
1178 | 0 | } |
1179 | 0 | } |
1180 | | |
1181 | | #ifndef Q_QDOC |
1182 | | |
1183 | | #ifndef NDEBUG |
1184 | | #define I18N_ERR_MSG String_literal_as_second_argument_to_i18n___Perhaps_you_need_i18nc_or_i18np |
1185 | | template<typename T, int s> |
1186 | | class I18nTypeCheck |
1187 | | { |
1188 | | public: |
1189 | | static void I18N_ERR_MSG() |
1190 | | { |
1191 | | } |
1192 | | }; |
1193 | | template<int s> |
1194 | | class I18nTypeCheck<char[s], s> |
1195 | | { |
1196 | | }; |
1197 | | #define STATIC_ASSERT_NOT_LITERAL_STRING(T) I18nTypeCheck<T, sizeof(T)>::I18N_ERR_MSG(); |
1198 | | #else |
1199 | | #define STATIC_ASSERT_NOT_LITERAL_STRING(T) |
1200 | | #endif |
1201 | | |
1202 | | // >>>>> Basic calls |
1203 | | // Autogenerated; contact maintainer for batch changes. |
1204 | | inline QString i18n(const char *text) |
1205 | 0 | { |
1206 | 0 | return ki18n(text).toString(); |
1207 | 0 | } |
1208 | | template<typename A1> |
1209 | | inline QString i18n(const char *text, const A1 &a1) |
1210 | | { |
1211 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1212 | | return ki18n(text).subs(a1).toString(); |
1213 | | } |
1214 | | template<typename A1, typename A2> |
1215 | | inline QString i18n(const char *text, const A1 &a1, const A2 &a2) |
1216 | | { |
1217 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1218 | | return ki18n(text).subs(a1).subs(a2).toString(); |
1219 | | } |
1220 | | template<typename A1, typename A2, typename A3> |
1221 | | inline QString i18n(const char *text, const A1 &a1, const A2 &a2, const A3 &a3) |
1222 | | { |
1223 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1224 | | return ki18n(text).subs(a1).subs(a2).subs(a3).toString(); |
1225 | | } |
1226 | | template<typename A1, typename A2, typename A3, typename A4> |
1227 | | inline QString i18n(const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4) |
1228 | | { |
1229 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1230 | | return ki18n(text).subs(a1).subs(a2).subs(a3).subs(a4).toString(); |
1231 | | } |
1232 | | template<typename A1, typename A2, typename A3, typename A4, typename A5> |
1233 | | inline QString i18n(const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5) |
1234 | | { |
1235 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1236 | | return ki18n(text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).toString(); |
1237 | | } |
1238 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> |
1239 | | inline QString i18n(const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6) |
1240 | | { |
1241 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1242 | | return ki18n(text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).toString(); |
1243 | | } |
1244 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> |
1245 | | inline QString i18n(const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7) |
1246 | | { |
1247 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1248 | | return ki18n(text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).toString(); |
1249 | | } |
1250 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> |
1251 | | inline QString i18n(const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7, const A8 &a8) |
1252 | | { |
1253 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1254 | | return ki18n(text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).toString(); |
1255 | | } |
1256 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> |
1257 | | inline QString |
1258 | | i18n(const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7, const A8 &a8, const A9 &a9) |
1259 | | { |
1260 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1261 | | return ki18n(text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).subs(a9).toString(); |
1262 | | } |
1263 | | // <<<<<<< End of basic calls |
1264 | | |
1265 | | // >>>>> Context calls |
1266 | | // Autogenerated; contact maintainer for batch changes. |
1267 | | inline QString i18nc(const char *context, const char *text) |
1268 | 0 | { |
1269 | 0 | return ki18nc(context, text).toString(); |
1270 | 0 | } |
1271 | | template<typename A1> |
1272 | | inline QString i18nc(const char *context, const char *text, const A1 &a1) |
1273 | | { |
1274 | | return ki18nc(context, text).subs(a1).toString(); |
1275 | | } |
1276 | | template<typename A1, typename A2> |
1277 | | inline QString i18nc(const char *context, const char *text, const A1 &a1, const A2 &a2) |
1278 | | { |
1279 | | return ki18nc(context, text).subs(a1).subs(a2).toString(); |
1280 | | } |
1281 | | template<typename A1, typename A2, typename A3> |
1282 | | inline QString i18nc(const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3) |
1283 | | { |
1284 | | return ki18nc(context, text).subs(a1).subs(a2).subs(a3).toString(); |
1285 | | } |
1286 | | template<typename A1, typename A2, typename A3, typename A4> |
1287 | | inline QString i18nc(const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4) |
1288 | | { |
1289 | | return ki18nc(context, text).subs(a1).subs(a2).subs(a3).subs(a4).toString(); |
1290 | | } |
1291 | | template<typename A1, typename A2, typename A3, typename A4, typename A5> |
1292 | | inline QString i18nc(const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5) |
1293 | | { |
1294 | | return ki18nc(context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).toString(); |
1295 | | } |
1296 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> |
1297 | | inline QString i18nc(const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6) |
1298 | | { |
1299 | | return ki18nc(context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).toString(); |
1300 | | } |
1301 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> |
1302 | | inline QString i18nc(const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7) |
1303 | | { |
1304 | | return ki18nc(context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).toString(); |
1305 | | } |
1306 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> |
1307 | | inline QString |
1308 | | i18nc(const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7, const A8 &a8) |
1309 | | { |
1310 | | return ki18nc(context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).toString(); |
1311 | | } |
1312 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> |
1313 | | inline QString i18nc(const char *context, |
1314 | | const char *text, |
1315 | | const A1 &a1, |
1316 | | const A2 &a2, |
1317 | | const A3 &a3, |
1318 | | const A4 &a4, |
1319 | | const A5 &a5, |
1320 | | const A6 &a6, |
1321 | | const A7 &a7, |
1322 | | const A8 &a8, |
1323 | | const A9 &a9) |
1324 | | { |
1325 | | return ki18nc(context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).subs(a9).toString(); |
1326 | | } |
1327 | | // <<<<< End of context calls |
1328 | | |
1329 | | // >>>>> Plural calls |
1330 | | // Autogenerated; contact maintainer for batch changes. |
1331 | | template<typename A1> |
1332 | | inline QString i18np(const char *singular, const char *plural, const A1 &a1) |
1333 | | { |
1334 | | return ki18np(singular, plural).subs(a1).toString(); |
1335 | | } |
1336 | | template<typename A1, typename A2> |
1337 | | inline QString i18np(const char *singular, const char *plural, const A1 &a1, const A2 &a2) |
1338 | | { |
1339 | | return ki18np(singular, plural).subs(a1).subs(a2).toString(); |
1340 | | } |
1341 | | template<typename A1, typename A2, typename A3> |
1342 | | inline QString i18np(const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3) |
1343 | | { |
1344 | | return ki18np(singular, plural).subs(a1).subs(a2).subs(a3).toString(); |
1345 | | } |
1346 | | template<typename A1, typename A2, typename A3, typename A4> |
1347 | | inline QString i18np(const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4) |
1348 | | { |
1349 | | return ki18np(singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).toString(); |
1350 | | } |
1351 | | template<typename A1, typename A2, typename A3, typename A4, typename A5> |
1352 | | inline QString i18np(const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5) |
1353 | | { |
1354 | | return ki18np(singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).toString(); |
1355 | | } |
1356 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> |
1357 | | inline QString i18np(const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6) |
1358 | | { |
1359 | | return ki18np(singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).toString(); |
1360 | | } |
1361 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> |
1362 | | inline QString i18np(const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7) |
1363 | | { |
1364 | | return ki18np(singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).toString(); |
1365 | | } |
1366 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> |
1367 | | inline QString |
1368 | | i18np(const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7, const A8 &a8) |
1369 | | { |
1370 | | return ki18np(singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).toString(); |
1371 | | } |
1372 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> |
1373 | | inline QString i18np(const char *singular, |
1374 | | const char *plural, |
1375 | | const A1 &a1, |
1376 | | const A2 &a2, |
1377 | | const A3 &a3, |
1378 | | const A4 &a4, |
1379 | | const A5 &a5, |
1380 | | const A6 &a6, |
1381 | | const A7 &a7, |
1382 | | const A8 &a8, |
1383 | | const A9 &a9) |
1384 | | { |
1385 | | return ki18np(singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).subs(a9).toString(); |
1386 | | } |
1387 | | // <<<<< End of plural calls |
1388 | | |
1389 | | // >>>>> Context-plural calls |
1390 | | // Autogenerated; contact maintainer for batch changes. |
1391 | | template<typename A1> |
1392 | | inline QString i18ncp(const char *context, const char *singular, const char *plural, const A1 &a1) |
1393 | | { |
1394 | | return ki18ncp(context, singular, plural).subs(a1).toString(); |
1395 | | } |
1396 | | template<typename A1, typename A2> |
1397 | | inline QString i18ncp(const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2) |
1398 | | { |
1399 | | return ki18ncp(context, singular, plural).subs(a1).subs(a2).toString(); |
1400 | | } |
1401 | | template<typename A1, typename A2, typename A3> |
1402 | | inline QString i18ncp(const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3) |
1403 | | { |
1404 | | return ki18ncp(context, singular, plural).subs(a1).subs(a2).subs(a3).toString(); |
1405 | | } |
1406 | | template<typename A1, typename A2, typename A3, typename A4> |
1407 | | inline QString i18ncp(const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4) |
1408 | | { |
1409 | | return ki18ncp(context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).toString(); |
1410 | | } |
1411 | | template<typename A1, typename A2, typename A3, typename A4, typename A5> |
1412 | | inline QString i18ncp(const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5) |
1413 | | { |
1414 | | return ki18ncp(context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).toString(); |
1415 | | } |
1416 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> |
1417 | | inline QString |
1418 | | i18ncp(const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6) |
1419 | | { |
1420 | | return ki18ncp(context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).toString(); |
1421 | | } |
1422 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> |
1423 | | inline QString i18ncp(const char *context, |
1424 | | const char *singular, |
1425 | | const char *plural, |
1426 | | const A1 &a1, |
1427 | | const A2 &a2, |
1428 | | const A3 &a3, |
1429 | | const A4 &a4, |
1430 | | const A5 &a5, |
1431 | | const A6 &a6, |
1432 | | const A7 &a7) |
1433 | | { |
1434 | | return ki18ncp(context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).toString(); |
1435 | | } |
1436 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> |
1437 | | inline QString i18ncp(const char *context, |
1438 | | const char *singular, |
1439 | | const char *plural, |
1440 | | const A1 &a1, |
1441 | | const A2 &a2, |
1442 | | const A3 &a3, |
1443 | | const A4 &a4, |
1444 | | const A5 &a5, |
1445 | | const A6 &a6, |
1446 | | const A7 &a7, |
1447 | | const A8 &a8) |
1448 | | { |
1449 | | return ki18ncp(context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).toString(); |
1450 | | } |
1451 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> |
1452 | | inline QString i18ncp(const char *context, |
1453 | | const char *singular, |
1454 | | const char *plural, |
1455 | | const A1 &a1, |
1456 | | const A2 &a2, |
1457 | | const A3 &a3, |
1458 | | const A4 &a4, |
1459 | | const A5 &a5, |
1460 | | const A6 &a6, |
1461 | | const A7 &a7, |
1462 | | const A8 &a8, |
1463 | | const A9 &a9) |
1464 | | { |
1465 | | return ki18ncp(context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).subs(a9).toString(); |
1466 | | } |
1467 | | // <<<<< End of context-plural calls |
1468 | | |
1469 | | // >>>>> Basic calls with domain |
1470 | | // Autogenerated; contact maintainer for batch changes. |
1471 | | inline QString i18nd(const char *domain, const char *text) |
1472 | 0 | { |
1473 | 0 | return ki18nd(domain, text).toString(); |
1474 | 0 | } |
1475 | | template<typename A1> |
1476 | | inline QString i18nd(const char *domain, const char *text, const A1 &a1) |
1477 | | { |
1478 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1479 | | return ki18nd(domain, text).subs(a1).toString(); |
1480 | | } |
1481 | | template<typename A1, typename A2> |
1482 | | inline QString i18nd(const char *domain, const char *text, const A1 &a1, const A2 &a2) |
1483 | | { |
1484 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1485 | | return ki18nd(domain, text).subs(a1).subs(a2).toString(); |
1486 | | } |
1487 | | template<typename A1, typename A2, typename A3> |
1488 | | inline QString i18nd(const char *domain, const char *text, const A1 &a1, const A2 &a2, const A3 &a3) |
1489 | | { |
1490 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1491 | | return ki18nd(domain, text).subs(a1).subs(a2).subs(a3).toString(); |
1492 | | } |
1493 | | template<typename A1, typename A2, typename A3, typename A4> |
1494 | | inline QString i18nd(const char *domain, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4) |
1495 | | { |
1496 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1497 | | return ki18nd(domain, text).subs(a1).subs(a2).subs(a3).subs(a4).toString(); |
1498 | | } |
1499 | | template<typename A1, typename A2, typename A3, typename A4, typename A5> |
1500 | | inline QString i18nd(const char *domain, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5) |
1501 | | { |
1502 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1503 | | return ki18nd(domain, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).toString(); |
1504 | | } |
1505 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> |
1506 | | inline QString i18nd(const char *domain, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6) |
1507 | | { |
1508 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1509 | | return ki18nd(domain, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).toString(); |
1510 | | } |
1511 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> |
1512 | | inline QString i18nd(const char *domain, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7) |
1513 | | { |
1514 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1515 | | return ki18nd(domain, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).toString(); |
1516 | | } |
1517 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> |
1518 | | inline QString |
1519 | | i18nd(const char *domain, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7, const A8 &a8) |
1520 | | { |
1521 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1522 | | return ki18nd(domain, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).toString(); |
1523 | | } |
1524 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> |
1525 | | inline QString i18nd(const char *domain, |
1526 | | const char *text, |
1527 | | const A1 &a1, |
1528 | | const A2 &a2, |
1529 | | const A3 &a3, |
1530 | | const A4 &a4, |
1531 | | const A5 &a5, |
1532 | | const A6 &a6, |
1533 | | const A7 &a7, |
1534 | | const A8 &a8, |
1535 | | const A9 &a9) |
1536 | | { |
1537 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1538 | | return ki18nd(domain, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).subs(a9).toString(); |
1539 | | } |
1540 | | // <<<<<<< End of basic calls with domain |
1541 | | |
1542 | | // >>>>> Context calls with domain |
1543 | | // Autogenerated; contact maintainer for batch changes. |
1544 | | inline QString i18ndc(const char *domain, const char *context, const char *text) |
1545 | 0 | { |
1546 | 0 | return ki18ndc(domain, context, text).toString(); |
1547 | 0 | } |
1548 | | template<typename A1> |
1549 | | inline QString i18ndc(const char *domain, const char *context, const char *text, const A1 &a1) |
1550 | | { |
1551 | | return ki18ndc(domain, context, text).subs(a1).toString(); |
1552 | | } |
1553 | | template<typename A1, typename A2> |
1554 | | inline QString i18ndc(const char *domain, const char *context, const char *text, const A1 &a1, const A2 &a2) |
1555 | | { |
1556 | | return ki18ndc(domain, context, text).subs(a1).subs(a2).toString(); |
1557 | | } |
1558 | | template<typename A1, typename A2, typename A3> |
1559 | | inline QString i18ndc(const char *domain, const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3) |
1560 | | { |
1561 | | return ki18ndc(domain, context, text).subs(a1).subs(a2).subs(a3).toString(); |
1562 | | } |
1563 | | template<typename A1, typename A2, typename A3, typename A4> |
1564 | | inline QString i18ndc(const char *domain, const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4) |
1565 | | { |
1566 | | return ki18ndc(domain, context, text).subs(a1).subs(a2).subs(a3).subs(a4).toString(); |
1567 | | } |
1568 | | template<typename A1, typename A2, typename A3, typename A4, typename A5> |
1569 | | inline QString i18ndc(const char *domain, const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5) |
1570 | | { |
1571 | | return ki18ndc(domain, context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).toString(); |
1572 | | } |
1573 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> |
1574 | | inline QString |
1575 | | i18ndc(const char *domain, const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6) |
1576 | | { |
1577 | | return ki18ndc(domain, context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).toString(); |
1578 | | } |
1579 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> |
1580 | | inline QString i18ndc(const char *domain, |
1581 | | const char *context, |
1582 | | const char *text, |
1583 | | const A1 &a1, |
1584 | | const A2 &a2, |
1585 | | const A3 &a3, |
1586 | | const A4 &a4, |
1587 | | const A5 &a5, |
1588 | | const A6 &a6, |
1589 | | const A7 &a7) |
1590 | | { |
1591 | | return ki18ndc(domain, context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).toString(); |
1592 | | } |
1593 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> |
1594 | | inline QString i18ndc(const char *domain, |
1595 | | const char *context, |
1596 | | const char *text, |
1597 | | const A1 &a1, |
1598 | | const A2 &a2, |
1599 | | const A3 &a3, |
1600 | | const A4 &a4, |
1601 | | const A5 &a5, |
1602 | | const A6 &a6, |
1603 | | const A7 &a7, |
1604 | | const A8 &a8) |
1605 | | { |
1606 | | return ki18ndc(domain, context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).toString(); |
1607 | | } |
1608 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> |
1609 | | inline QString i18ndc(const char *domain, |
1610 | | const char *context, |
1611 | | const char *text, |
1612 | | const A1 &a1, |
1613 | | const A2 &a2, |
1614 | | const A3 &a3, |
1615 | | const A4 &a4, |
1616 | | const A5 &a5, |
1617 | | const A6 &a6, |
1618 | | const A7 &a7, |
1619 | | const A8 &a8, |
1620 | | const A9 &a9) |
1621 | | { |
1622 | | return ki18ndc(domain, context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).subs(a9).toString(); |
1623 | | } |
1624 | | // <<<<< End of context calls with domain |
1625 | | |
1626 | | // >>>>> Plural calls with domain |
1627 | | // Autogenerated; contact maintainer for batch changes. |
1628 | | template<typename A1> |
1629 | | inline QString i18ndp(const char *domain, const char *singular, const char *plural, const A1 &a1) |
1630 | | { |
1631 | | return ki18ndp(domain, singular, plural).subs(a1).toString(); |
1632 | | } |
1633 | | template<typename A1, typename A2> |
1634 | | inline QString i18ndp(const char *domain, const char *singular, const char *plural, const A1 &a1, const A2 &a2) |
1635 | | { |
1636 | | return ki18ndp(domain, singular, plural).subs(a1).subs(a2).toString(); |
1637 | | } |
1638 | | template<typename A1, typename A2, typename A3> |
1639 | | inline QString i18ndp(const char *domain, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3) |
1640 | | { |
1641 | | return ki18ndp(domain, singular, plural).subs(a1).subs(a2).subs(a3).toString(); |
1642 | | } |
1643 | | template<typename A1, typename A2, typename A3, typename A4> |
1644 | | inline QString i18ndp(const char *domain, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4) |
1645 | | { |
1646 | | return ki18ndp(domain, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).toString(); |
1647 | | } |
1648 | | template<typename A1, typename A2, typename A3, typename A4, typename A5> |
1649 | | inline QString i18ndp(const char *domain, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5) |
1650 | | { |
1651 | | return ki18ndp(domain, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).toString(); |
1652 | | } |
1653 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> |
1654 | | inline QString |
1655 | | i18ndp(const char *domain, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6) |
1656 | | { |
1657 | | return ki18ndp(domain, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).toString(); |
1658 | | } |
1659 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> |
1660 | | inline QString i18ndp(const char *domain, |
1661 | | const char *singular, |
1662 | | const char *plural, |
1663 | | const A1 &a1, |
1664 | | const A2 &a2, |
1665 | | const A3 &a3, |
1666 | | const A4 &a4, |
1667 | | const A5 &a5, |
1668 | | const A6 &a6, |
1669 | | const A7 &a7) |
1670 | | { |
1671 | | return ki18ndp(domain, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).toString(); |
1672 | | } |
1673 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> |
1674 | | inline QString i18ndp(const char *domain, |
1675 | | const char *singular, |
1676 | | const char *plural, |
1677 | | const A1 &a1, |
1678 | | const A2 &a2, |
1679 | | const A3 &a3, |
1680 | | const A4 &a4, |
1681 | | const A5 &a5, |
1682 | | const A6 &a6, |
1683 | | const A7 &a7, |
1684 | | const A8 &a8) |
1685 | | { |
1686 | | return ki18ndp(domain, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).toString(); |
1687 | | } |
1688 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> |
1689 | | inline QString i18ndp(const char *domain, |
1690 | | const char *singular, |
1691 | | const char *plural, |
1692 | | const A1 &a1, |
1693 | | const A2 &a2, |
1694 | | const A3 &a3, |
1695 | | const A4 &a4, |
1696 | | const A5 &a5, |
1697 | | const A6 &a6, |
1698 | | const A7 &a7, |
1699 | | const A8 &a8, |
1700 | | const A9 &a9) |
1701 | | { |
1702 | | return ki18ndp(domain, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).subs(a9).toString(); |
1703 | | } |
1704 | | // <<<<< End of plural calls with domain |
1705 | | |
1706 | | // >>>>> Context-plural calls with domain |
1707 | | // Autogenerated; contact maintainer for batch changes. |
1708 | | template<typename A1> |
1709 | | inline QString i18ndcp(const char *domain, const char *context, const char *singular, const char *plural, const A1 &a1) |
1710 | | { |
1711 | | return ki18ndcp(domain, context, singular, plural).subs(a1).toString(); |
1712 | | } |
1713 | | template<typename A1, typename A2> |
1714 | | inline QString i18ndcp(const char *domain, const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2) |
1715 | | { |
1716 | | return ki18ndcp(domain, context, singular, plural).subs(a1).subs(a2).toString(); |
1717 | | } |
1718 | | template<typename A1, typename A2, typename A3> |
1719 | | inline QString i18ndcp(const char *domain, const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3) |
1720 | | { |
1721 | | return ki18ndcp(domain, context, singular, plural).subs(a1).subs(a2).subs(a3).toString(); |
1722 | | } |
1723 | | template<typename A1, typename A2, typename A3, typename A4> |
1724 | | inline QString |
1725 | | i18ndcp(const char *domain, const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4) |
1726 | | { |
1727 | | return ki18ndcp(domain, context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).toString(); |
1728 | | } |
1729 | | template<typename A1, typename A2, typename A3, typename A4, typename A5> |
1730 | | inline QString |
1731 | | i18ndcp(const char *domain, const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5) |
1732 | | { |
1733 | | return ki18ndcp(domain, context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).toString(); |
1734 | | } |
1735 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> |
1736 | | inline QString i18ndcp(const char *domain, |
1737 | | const char *context, |
1738 | | const char *singular, |
1739 | | const char *plural, |
1740 | | const A1 &a1, |
1741 | | const A2 &a2, |
1742 | | const A3 &a3, |
1743 | | const A4 &a4, |
1744 | | const A5 &a5, |
1745 | | const A6 &a6) |
1746 | | { |
1747 | | return ki18ndcp(domain, context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).toString(); |
1748 | | } |
1749 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> |
1750 | | inline QString i18ndcp(const char *domain, |
1751 | | const char *context, |
1752 | | const char *singular, |
1753 | | const char *plural, |
1754 | | const A1 &a1, |
1755 | | const A2 &a2, |
1756 | | const A3 &a3, |
1757 | | const A4 &a4, |
1758 | | const A5 &a5, |
1759 | | const A6 &a6, |
1760 | | const A7 &a7) |
1761 | | { |
1762 | | return ki18ndcp(domain, context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).toString(); |
1763 | | } |
1764 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> |
1765 | | inline QString i18ndcp(const char *domain, |
1766 | | const char *context, |
1767 | | const char *singular, |
1768 | | const char *plural, |
1769 | | const A1 &a1, |
1770 | | const A2 &a2, |
1771 | | const A3 &a3, |
1772 | | const A4 &a4, |
1773 | | const A5 &a5, |
1774 | | const A6 &a6, |
1775 | | const A7 &a7, |
1776 | | const A8 &a8) |
1777 | | { |
1778 | | return ki18ndcp(domain, context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).toString(); |
1779 | | } |
1780 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> |
1781 | | inline QString i18ndcp(const char *domain, |
1782 | | const char *context, |
1783 | | const char *singular, |
1784 | | const char *plural, |
1785 | | const A1 &a1, |
1786 | | const A2 &a2, |
1787 | | const A3 &a3, |
1788 | | const A4 &a4, |
1789 | | const A5 &a5, |
1790 | | const A6 &a6, |
1791 | | const A7 &a7, |
1792 | | const A8 &a8, |
1793 | | const A9 &a9) |
1794 | | { |
1795 | | return ki18ndcp(domain, context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).subs(a9).toString(); |
1796 | | } |
1797 | | // <<<<< End of context-plural calls with domain |
1798 | | |
1799 | | // >>>>> Markup-aware basic calls |
1800 | | // Autogenerated; contact maintainer for batch changes. |
1801 | | inline QString xi18n(const char *text) |
1802 | 0 | { |
1803 | 0 | return kxi18n(text).toString(); |
1804 | 0 | } |
1805 | | template<typename A1> |
1806 | | inline QString xi18n(const char *text, const A1 &a1) |
1807 | | { |
1808 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1809 | | return kxi18n(text).subs(a1).toString(); |
1810 | | } |
1811 | | template<typename A1, typename A2> |
1812 | | inline QString xi18n(const char *text, const A1 &a1, const A2 &a2) |
1813 | | { |
1814 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1815 | | return kxi18n(text).subs(a1).subs(a2).toString(); |
1816 | | } |
1817 | | template<typename A1, typename A2, typename A3> |
1818 | | inline QString xi18n(const char *text, const A1 &a1, const A2 &a2, const A3 &a3) |
1819 | | { |
1820 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1821 | | return kxi18n(text).subs(a1).subs(a2).subs(a3).toString(); |
1822 | | } |
1823 | | template<typename A1, typename A2, typename A3, typename A4> |
1824 | | inline QString xi18n(const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4) |
1825 | | { |
1826 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1827 | | return kxi18n(text).subs(a1).subs(a2).subs(a3).subs(a4).toString(); |
1828 | | } |
1829 | | template<typename A1, typename A2, typename A3, typename A4, typename A5> |
1830 | | inline QString xi18n(const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5) |
1831 | | { |
1832 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1833 | | return kxi18n(text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).toString(); |
1834 | | } |
1835 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> |
1836 | | inline QString xi18n(const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6) |
1837 | | { |
1838 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1839 | | return kxi18n(text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).toString(); |
1840 | | } |
1841 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> |
1842 | | inline QString xi18n(const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7) |
1843 | | { |
1844 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1845 | | return kxi18n(text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).toString(); |
1846 | | } |
1847 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> |
1848 | | inline QString xi18n(const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7, const A8 &a8) |
1849 | | { |
1850 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1851 | | return kxi18n(text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).toString(); |
1852 | | } |
1853 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> |
1854 | | inline QString |
1855 | | xi18n(const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7, const A8 &a8, const A9 &a9) |
1856 | | { |
1857 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
1858 | | return kxi18n(text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).subs(a9).toString(); |
1859 | | } |
1860 | | // <<<<<<< End of markup-aware basic calls |
1861 | | |
1862 | | // >>>>> Markup-aware context calls |
1863 | | // Autogenerated; contact maintainer for batch changes. |
1864 | | inline QString xi18nc(const char *context, const char *text) |
1865 | 0 | { |
1866 | 0 | return kxi18nc(context, text).toString(); |
1867 | 0 | } |
1868 | | template<typename A1> |
1869 | | inline QString xi18nc(const char *context, const char *text, const A1 &a1) |
1870 | | { |
1871 | | return kxi18nc(context, text).subs(a1).toString(); |
1872 | | } |
1873 | | template<typename A1, typename A2> |
1874 | | inline QString xi18nc(const char *context, const char *text, const A1 &a1, const A2 &a2) |
1875 | | { |
1876 | | return kxi18nc(context, text).subs(a1).subs(a2).toString(); |
1877 | | } |
1878 | | template<typename A1, typename A2, typename A3> |
1879 | | inline QString xi18nc(const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3) |
1880 | | { |
1881 | | return kxi18nc(context, text).subs(a1).subs(a2).subs(a3).toString(); |
1882 | | } |
1883 | | template<typename A1, typename A2, typename A3, typename A4> |
1884 | | inline QString xi18nc(const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4) |
1885 | | { |
1886 | | return kxi18nc(context, text).subs(a1).subs(a2).subs(a3).subs(a4).toString(); |
1887 | | } |
1888 | | template<typename A1, typename A2, typename A3, typename A4, typename A5> |
1889 | | inline QString xi18nc(const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5) |
1890 | | { |
1891 | | return kxi18nc(context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).toString(); |
1892 | | } |
1893 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> |
1894 | | inline QString xi18nc(const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6) |
1895 | | { |
1896 | | return kxi18nc(context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).toString(); |
1897 | | } |
1898 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> |
1899 | | inline QString xi18nc(const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7) |
1900 | | { |
1901 | | return kxi18nc(context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).toString(); |
1902 | | } |
1903 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> |
1904 | | inline QString |
1905 | | xi18nc(const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7, const A8 &a8) |
1906 | | { |
1907 | | return kxi18nc(context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).toString(); |
1908 | | } |
1909 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> |
1910 | | inline QString xi18nc(const char *context, |
1911 | | const char *text, |
1912 | | const A1 &a1, |
1913 | | const A2 &a2, |
1914 | | const A3 &a3, |
1915 | | const A4 &a4, |
1916 | | const A5 &a5, |
1917 | | const A6 &a6, |
1918 | | const A7 &a7, |
1919 | | const A8 &a8, |
1920 | | const A9 &a9) |
1921 | | { |
1922 | | return kxi18nc(context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).subs(a9).toString(); |
1923 | | } |
1924 | | // <<<<< End of markup-aware context calls |
1925 | | |
1926 | | // >>>>> Markup-aware plural calls |
1927 | | // Autogenerated; contact maintainer for batch changes. |
1928 | | template<typename A1> |
1929 | | inline QString xi18np(const char *singular, const char *plural, const A1 &a1) |
1930 | | { |
1931 | | return kxi18np(singular, plural).subs(a1).toString(); |
1932 | | } |
1933 | | template<typename A1, typename A2> |
1934 | | inline QString xi18np(const char *singular, const char *plural, const A1 &a1, const A2 &a2) |
1935 | | { |
1936 | | return kxi18np(singular, plural).subs(a1).subs(a2).toString(); |
1937 | | } |
1938 | | template<typename A1, typename A2, typename A3> |
1939 | | inline QString xi18np(const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3) |
1940 | | { |
1941 | | return kxi18np(singular, plural).subs(a1).subs(a2).subs(a3).toString(); |
1942 | | } |
1943 | | template<typename A1, typename A2, typename A3, typename A4> |
1944 | | inline QString xi18np(const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4) |
1945 | | { |
1946 | | return kxi18np(singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).toString(); |
1947 | | } |
1948 | | template<typename A1, typename A2, typename A3, typename A4, typename A5> |
1949 | | inline QString xi18np(const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5) |
1950 | | { |
1951 | | return kxi18np(singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).toString(); |
1952 | | } |
1953 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> |
1954 | | inline QString xi18np(const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6) |
1955 | | { |
1956 | | return kxi18np(singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).toString(); |
1957 | | } |
1958 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> |
1959 | | inline QString |
1960 | | xi18np(const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7) |
1961 | | { |
1962 | | return kxi18np(singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).toString(); |
1963 | | } |
1964 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> |
1965 | | inline QString |
1966 | | xi18np(const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7, const A8 &a8) |
1967 | | { |
1968 | | return kxi18np(singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).toString(); |
1969 | | } |
1970 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> |
1971 | | inline QString xi18np(const char *singular, |
1972 | | const char *plural, |
1973 | | const A1 &a1, |
1974 | | const A2 &a2, |
1975 | | const A3 &a3, |
1976 | | const A4 &a4, |
1977 | | const A5 &a5, |
1978 | | const A6 &a6, |
1979 | | const A7 &a7, |
1980 | | const A8 &a8, |
1981 | | const A9 &a9) |
1982 | | { |
1983 | | return kxi18np(singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).subs(a9).toString(); |
1984 | | } |
1985 | | // <<<<< End of markup-aware plural calls |
1986 | | |
1987 | | // >>>>> Markup-aware context-plural calls |
1988 | | // Autogenerated; contact maintainer for batch changes. |
1989 | | template<typename A1> |
1990 | | inline QString xi18ncp(const char *context, const char *singular, const char *plural, const A1 &a1) |
1991 | | { |
1992 | | return kxi18ncp(context, singular, plural).subs(a1).toString(); |
1993 | | } |
1994 | | template<typename A1, typename A2> |
1995 | | inline QString xi18ncp(const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2) |
1996 | | { |
1997 | | return kxi18ncp(context, singular, plural).subs(a1).subs(a2).toString(); |
1998 | | } |
1999 | | template<typename A1, typename A2, typename A3> |
2000 | | inline QString xi18ncp(const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3) |
2001 | | { |
2002 | | return kxi18ncp(context, singular, plural).subs(a1).subs(a2).subs(a3).toString(); |
2003 | | } |
2004 | | template<typename A1, typename A2, typename A3, typename A4> |
2005 | | inline QString xi18ncp(const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4) |
2006 | | { |
2007 | | return kxi18ncp(context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).toString(); |
2008 | | } |
2009 | | template<typename A1, typename A2, typename A3, typename A4, typename A5> |
2010 | | inline QString xi18ncp(const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5) |
2011 | | { |
2012 | | return kxi18ncp(context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).toString(); |
2013 | | } |
2014 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> |
2015 | | inline QString |
2016 | | xi18ncp(const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6) |
2017 | | { |
2018 | | return kxi18ncp(context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).toString(); |
2019 | | } |
2020 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> |
2021 | | inline QString xi18ncp(const char *context, |
2022 | | const char *singular, |
2023 | | const char *plural, |
2024 | | const A1 &a1, |
2025 | | const A2 &a2, |
2026 | | const A3 &a3, |
2027 | | const A4 &a4, |
2028 | | const A5 &a5, |
2029 | | const A6 &a6, |
2030 | | const A7 &a7) |
2031 | | { |
2032 | | return kxi18ncp(context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).toString(); |
2033 | | } |
2034 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> |
2035 | | inline QString xi18ncp(const char *context, |
2036 | | const char *singular, |
2037 | | const char *plural, |
2038 | | const A1 &a1, |
2039 | | const A2 &a2, |
2040 | | const A3 &a3, |
2041 | | const A4 &a4, |
2042 | | const A5 &a5, |
2043 | | const A6 &a6, |
2044 | | const A7 &a7, |
2045 | | const A8 &a8) |
2046 | | { |
2047 | | return kxi18ncp(context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).toString(); |
2048 | | } |
2049 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> |
2050 | | inline QString xi18ncp(const char *context, |
2051 | | const char *singular, |
2052 | | const char *plural, |
2053 | | const A1 &a1, |
2054 | | const A2 &a2, |
2055 | | const A3 &a3, |
2056 | | const A4 &a4, |
2057 | | const A5 &a5, |
2058 | | const A6 &a6, |
2059 | | const A7 &a7, |
2060 | | const A8 &a8, |
2061 | | const A9 &a9) |
2062 | | { |
2063 | | return kxi18ncp(context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).subs(a9).toString(); |
2064 | | } |
2065 | | // <<<<< End of markup-aware context-plural calls |
2066 | | |
2067 | | // >>>>> Markup-aware basic calls with domain |
2068 | | // Autogenerated; contact maintainer for batch changes. |
2069 | | inline QString xi18nd(const char *domain, const char *text) |
2070 | 0 | { |
2071 | 0 | return kxi18nd(domain, text).toString(); |
2072 | 0 | } |
2073 | | template<typename A1> |
2074 | | inline QString xi18nd(const char *domain, const char *text, const A1 &a1) |
2075 | | { |
2076 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
2077 | | return kxi18nd(domain, text).subs(a1).toString(); |
2078 | | } |
2079 | | template<typename A1, typename A2> |
2080 | | inline QString xi18nd(const char *domain, const char *text, const A1 &a1, const A2 &a2) |
2081 | | { |
2082 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
2083 | | return kxi18nd(domain, text).subs(a1).subs(a2).toString(); |
2084 | | } |
2085 | | template<typename A1, typename A2, typename A3> |
2086 | | inline QString xi18nd(const char *domain, const char *text, const A1 &a1, const A2 &a2, const A3 &a3) |
2087 | | { |
2088 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
2089 | | return kxi18nd(domain, text).subs(a1).subs(a2).subs(a3).toString(); |
2090 | | } |
2091 | | template<typename A1, typename A2, typename A3, typename A4> |
2092 | | inline QString xi18nd(const char *domain, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4) |
2093 | | { |
2094 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
2095 | | return kxi18nd(domain, text).subs(a1).subs(a2).subs(a3).subs(a4).toString(); |
2096 | | } |
2097 | | template<typename A1, typename A2, typename A3, typename A4, typename A5> |
2098 | | inline QString xi18nd(const char *domain, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5) |
2099 | | { |
2100 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
2101 | | return kxi18nd(domain, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).toString(); |
2102 | | } |
2103 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> |
2104 | | inline QString xi18nd(const char *domain, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6) |
2105 | | { |
2106 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
2107 | | return kxi18nd(domain, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).toString(); |
2108 | | } |
2109 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> |
2110 | | inline QString xi18nd(const char *domain, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7) |
2111 | | { |
2112 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
2113 | | return kxi18nd(domain, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).toString(); |
2114 | | } |
2115 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> |
2116 | | inline QString |
2117 | | xi18nd(const char *domain, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6, const A7 &a7, const A8 &a8) |
2118 | | { |
2119 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
2120 | | return kxi18nd(domain, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).toString(); |
2121 | | } |
2122 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> |
2123 | | inline QString xi18nd(const char *domain, |
2124 | | const char *text, |
2125 | | const A1 &a1, |
2126 | | const A2 &a2, |
2127 | | const A3 &a3, |
2128 | | const A4 &a4, |
2129 | | const A5 &a5, |
2130 | | const A6 &a6, |
2131 | | const A7 &a7, |
2132 | | const A8 &a8, |
2133 | | const A9 &a9) |
2134 | | { |
2135 | | STATIC_ASSERT_NOT_LITERAL_STRING(A1) |
2136 | | return kxi18nd(domain, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).subs(a9).toString(); |
2137 | | } |
2138 | | // <<<<<<< End of markup-aware basic calls with domain |
2139 | | |
2140 | | // >>>>> Markup-aware context calls with domain |
2141 | | // Autogenerated; contact maintainer for batch changes. |
2142 | | inline QString xi18ndc(const char *domain, const char *context, const char *text) |
2143 | 0 | { |
2144 | 0 | return kxi18ndc(domain, context, text).toString(); |
2145 | 0 | } |
2146 | | template<typename A1> |
2147 | | inline QString xi18ndc(const char *domain, const char *context, const char *text, const A1 &a1) |
2148 | | { |
2149 | | return kxi18ndc(domain, context, text).subs(a1).toString(); |
2150 | | } |
2151 | | template<typename A1, typename A2> |
2152 | | inline QString xi18ndc(const char *domain, const char *context, const char *text, const A1 &a1, const A2 &a2) |
2153 | | { |
2154 | | return kxi18ndc(domain, context, text).subs(a1).subs(a2).toString(); |
2155 | | } |
2156 | | template<typename A1, typename A2, typename A3> |
2157 | | inline QString xi18ndc(const char *domain, const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3) |
2158 | | { |
2159 | | return kxi18ndc(domain, context, text).subs(a1).subs(a2).subs(a3).toString(); |
2160 | | } |
2161 | | template<typename A1, typename A2, typename A3, typename A4> |
2162 | | inline QString xi18ndc(const char *domain, const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4) |
2163 | | { |
2164 | | return kxi18ndc(domain, context, text).subs(a1).subs(a2).subs(a3).subs(a4).toString(); |
2165 | | } |
2166 | | template<typename A1, typename A2, typename A3, typename A4, typename A5> |
2167 | | inline QString xi18ndc(const char *domain, const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5) |
2168 | | { |
2169 | | return kxi18ndc(domain, context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).toString(); |
2170 | | } |
2171 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> |
2172 | | inline QString |
2173 | | xi18ndc(const char *domain, const char *context, const char *text, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6) |
2174 | | { |
2175 | | return kxi18ndc(domain, context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).toString(); |
2176 | | } |
2177 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> |
2178 | | inline QString xi18ndc(const char *domain, |
2179 | | const char *context, |
2180 | | const char *text, |
2181 | | const A1 &a1, |
2182 | | const A2 &a2, |
2183 | | const A3 &a3, |
2184 | | const A4 &a4, |
2185 | | const A5 &a5, |
2186 | | const A6 &a6, |
2187 | | const A7 &a7) |
2188 | | { |
2189 | | return kxi18ndc(domain, context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).toString(); |
2190 | | } |
2191 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> |
2192 | | inline QString xi18ndc(const char *domain, |
2193 | | const char *context, |
2194 | | const char *text, |
2195 | | const A1 &a1, |
2196 | | const A2 &a2, |
2197 | | const A3 &a3, |
2198 | | const A4 &a4, |
2199 | | const A5 &a5, |
2200 | | const A6 &a6, |
2201 | | const A7 &a7, |
2202 | | const A8 &a8) |
2203 | | { |
2204 | | return kxi18ndc(domain, context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).toString(); |
2205 | | } |
2206 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> |
2207 | | inline QString xi18ndc(const char *domain, |
2208 | | const char *context, |
2209 | | const char *text, |
2210 | | const A1 &a1, |
2211 | | const A2 &a2, |
2212 | | const A3 &a3, |
2213 | | const A4 &a4, |
2214 | | const A5 &a5, |
2215 | | const A6 &a6, |
2216 | | const A7 &a7, |
2217 | | const A8 &a8, |
2218 | | const A9 &a9) |
2219 | | { |
2220 | | return kxi18ndc(domain, context, text).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).subs(a9).toString(); |
2221 | | } |
2222 | | // <<<<< End of markup-aware context calls with domain |
2223 | | |
2224 | | // >>>>> Markup-aware plural calls with domain |
2225 | | // Autogenerated; contact maintainer for batch changes. |
2226 | | template<typename A1> |
2227 | | inline QString xi18ndp(const char *domain, const char *singular, const char *plural, const A1 &a1) |
2228 | | { |
2229 | | return kxi18ndp(domain, singular, plural).subs(a1).toString(); |
2230 | | } |
2231 | | template<typename A1, typename A2> |
2232 | | inline QString xi18ndp(const char *domain, const char *singular, const char *plural, const A1 &a1, const A2 &a2) |
2233 | | { |
2234 | | return kxi18ndp(domain, singular, plural).subs(a1).subs(a2).toString(); |
2235 | | } |
2236 | | template<typename A1, typename A2, typename A3> |
2237 | | inline QString xi18ndp(const char *domain, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3) |
2238 | | { |
2239 | | return kxi18ndp(domain, singular, plural).subs(a1).subs(a2).subs(a3).toString(); |
2240 | | } |
2241 | | template<typename A1, typename A2, typename A3, typename A4> |
2242 | | inline QString xi18ndp(const char *domain, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4) |
2243 | | { |
2244 | | return kxi18ndp(domain, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).toString(); |
2245 | | } |
2246 | | template<typename A1, typename A2, typename A3, typename A4, typename A5> |
2247 | | inline QString xi18ndp(const char *domain, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5) |
2248 | | { |
2249 | | return kxi18ndp(domain, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).toString(); |
2250 | | } |
2251 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> |
2252 | | inline QString |
2253 | | xi18ndp(const char *domain, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4, const A5 &a5, const A6 &a6) |
2254 | | { |
2255 | | return kxi18ndp(domain, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).toString(); |
2256 | | } |
2257 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> |
2258 | | inline QString xi18ndp(const char *domain, |
2259 | | const char *singular, |
2260 | | const char *plural, |
2261 | | const A1 &a1, |
2262 | | const A2 &a2, |
2263 | | const A3 &a3, |
2264 | | const A4 &a4, |
2265 | | const A5 &a5, |
2266 | | const A6 &a6, |
2267 | | const A7 &a7) |
2268 | | { |
2269 | | return kxi18ndp(domain, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).toString(); |
2270 | | } |
2271 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> |
2272 | | inline QString xi18ndp(const char *domain, |
2273 | | const char *singular, |
2274 | | const char *plural, |
2275 | | const A1 &a1, |
2276 | | const A2 &a2, |
2277 | | const A3 &a3, |
2278 | | const A4 &a4, |
2279 | | const A5 &a5, |
2280 | | const A6 &a6, |
2281 | | const A7 &a7, |
2282 | | const A8 &a8) |
2283 | | { |
2284 | | return kxi18ndp(domain, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).toString(); |
2285 | | } |
2286 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> |
2287 | | inline QString xi18ndp(const char *domain, |
2288 | | const char *singular, |
2289 | | const char *plural, |
2290 | | const A1 &a1, |
2291 | | const A2 &a2, |
2292 | | const A3 &a3, |
2293 | | const A4 &a4, |
2294 | | const A5 &a5, |
2295 | | const A6 &a6, |
2296 | | const A7 &a7, |
2297 | | const A8 &a8, |
2298 | | const A9 &a9) |
2299 | | { |
2300 | | return kxi18ndp(domain, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).subs(a9).toString(); |
2301 | | } |
2302 | | // <<<<< End of markup-aware plural calls with domain |
2303 | | |
2304 | | // >>>>> Markup-aware context-plural calls with domain |
2305 | | // Autogenerated; contact maintainer for batch changes. |
2306 | | template<typename A1> |
2307 | | inline QString xi18ndcp(const char *domain, const char *context, const char *singular, const char *plural, const A1 &a1) |
2308 | | { |
2309 | | return kxi18ndcp(domain, context, singular, plural).subs(a1).toString(); |
2310 | | } |
2311 | | template<typename A1, typename A2> |
2312 | | inline QString xi18ndcp(const char *domain, const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2) |
2313 | | { |
2314 | | return kxi18ndcp(domain, context, singular, plural).subs(a1).subs(a2).toString(); |
2315 | | } |
2316 | | template<typename A1, typename A2, typename A3> |
2317 | | inline QString xi18ndcp(const char *domain, const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3) |
2318 | | { |
2319 | | return kxi18ndcp(domain, context, singular, plural).subs(a1).subs(a2).subs(a3).toString(); |
2320 | | } |
2321 | | template<typename A1, typename A2, typename A3, typename A4> |
2322 | | inline QString |
2323 | | xi18ndcp(const char *domain, const char *context, const char *singular, const char *plural, const A1 &a1, const A2 &a2, const A3 &a3, const A4 &a4) |
2324 | | { |
2325 | | return kxi18ndcp(domain, context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).toString(); |
2326 | | } |
2327 | | template<typename A1, typename A2, typename A3, typename A4, typename A5> |
2328 | | inline QString xi18ndcp(const char *domain, |
2329 | | const char *context, |
2330 | | const char *singular, |
2331 | | const char *plural, |
2332 | | const A1 &a1, |
2333 | | const A2 &a2, |
2334 | | const A3 &a3, |
2335 | | const A4 &a4, |
2336 | | const A5 &a5) |
2337 | | { |
2338 | | return kxi18ndcp(domain, context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).toString(); |
2339 | | } |
2340 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6> |
2341 | | inline QString xi18ndcp(const char *domain, |
2342 | | const char *context, |
2343 | | const char *singular, |
2344 | | const char *plural, |
2345 | | const A1 &a1, |
2346 | | const A2 &a2, |
2347 | | const A3 &a3, |
2348 | | const A4 &a4, |
2349 | | const A5 &a5, |
2350 | | const A6 &a6) |
2351 | | { |
2352 | | return kxi18ndcp(domain, context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).toString(); |
2353 | | } |
2354 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7> |
2355 | | inline QString xi18ndcp(const char *domain, |
2356 | | const char *context, |
2357 | | const char *singular, |
2358 | | const char *plural, |
2359 | | const A1 &a1, |
2360 | | const A2 &a2, |
2361 | | const A3 &a3, |
2362 | | const A4 &a4, |
2363 | | const A5 &a5, |
2364 | | const A6 &a6, |
2365 | | const A7 &a7) |
2366 | | { |
2367 | | return kxi18ndcp(domain, context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).toString(); |
2368 | | } |
2369 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8> |
2370 | | inline QString xi18ndcp(const char *domain, |
2371 | | const char *context, |
2372 | | const char *singular, |
2373 | | const char *plural, |
2374 | | const A1 &a1, |
2375 | | const A2 &a2, |
2376 | | const A3 &a3, |
2377 | | const A4 &a4, |
2378 | | const A5 &a5, |
2379 | | const A6 &a6, |
2380 | | const A7 &a7, |
2381 | | const A8 &a8) |
2382 | | { |
2383 | | return kxi18ndcp(domain, context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).toString(); |
2384 | | } |
2385 | | template<typename A1, typename A2, typename A3, typename A4, typename A5, typename A6, typename A7, typename A8, typename A9> |
2386 | | inline QString xi18ndcp(const char *domain, |
2387 | | const char *context, |
2388 | | const char *singular, |
2389 | | const char *plural, |
2390 | | const A1 &a1, |
2391 | | const A2 &a2, |
2392 | | const A3 &a3, |
2393 | | const A4 &a4, |
2394 | | const A5 &a5, |
2395 | | const A6 &a6, |
2396 | | const A7 &a7, |
2397 | | const A8 &a8, |
2398 | | const A9 &a9) |
2399 | | { |
2400 | | return kxi18ndcp(domain, context, singular, plural).subs(a1).subs(a2).subs(a3).subs(a4).subs(a5).subs(a6).subs(a7).subs(a8).subs(a9).toString(); |
2401 | | } |
2402 | | // <<<<< End of markup-aware context-plural calls with domain |
2403 | | |
2404 | | #endif // Q_QDOC |
2405 | | |
2406 | | #endif // KLOCALIZEDSTRING_H |
2407 | | |
2408 | | #ifndef Q_QDOC |
2409 | | |
2410 | | // Outside of include guards, to be able to map and unmap domains |
2411 | | // by successive inclusions of this header |
2412 | | // preceded with different definitions of TRANSLATION_DOMAIN. |
2413 | | #ifdef TRANSLATION_DOMAIN |
2414 | | #define i18n(...) i18nd(TRANSLATION_DOMAIN, __VA_ARGS__) |
2415 | | #define i18nc(...) i18ndc(TRANSLATION_DOMAIN, __VA_ARGS__) |
2416 | | #define i18np(...) i18ndp(TRANSLATION_DOMAIN, __VA_ARGS__) |
2417 | | #define i18ncp(...) i18ndcp(TRANSLATION_DOMAIN, __VA_ARGS__) |
2418 | | #define ki18n(...) ki18nd(TRANSLATION_DOMAIN, __VA_ARGS__) |
2419 | 0 | #define ki18nc(...) ki18ndc(TRANSLATION_DOMAIN, __VA_ARGS__) |
2420 | | #define ki18np(...) ki18ndp(TRANSLATION_DOMAIN, __VA_ARGS__) |
2421 | | #define ki18ncp(...) ki18ndcp(TRANSLATION_DOMAIN, __VA_ARGS__) |
2422 | | #define tr2i18n(...) tr2i18nd(TRANSLATION_DOMAIN, __VA_ARGS__) |
2423 | | #define xi18n(...) xi18nd(TRANSLATION_DOMAIN, __VA_ARGS__) |
2424 | | #define xi18nc(...) xi18ndc(TRANSLATION_DOMAIN, __VA_ARGS__) |
2425 | | #define xi18np(...) xi18ndp(TRANSLATION_DOMAIN, __VA_ARGS__) |
2426 | | #define xi18ncp(...) xi18ndcp(TRANSLATION_DOMAIN, __VA_ARGS__) |
2427 | | #define kxi18n(...) kxi18nd(TRANSLATION_DOMAIN, __VA_ARGS__) |
2428 | | #define kxi18nc(...) kxi18ndc(TRANSLATION_DOMAIN, __VA_ARGS__) |
2429 | | #define kxi18np(...) kxi18ndp(TRANSLATION_DOMAIN, __VA_ARGS__) |
2430 | | #define kxi18ncp(...) kxi18ndcp(TRANSLATION_DOMAIN, __VA_ARGS__) |
2431 | | #define tr2xi18n(...) tr2xi18nd(TRANSLATION_DOMAIN, __VA_ARGS__) |
2432 | | #else |
2433 | | #undef i18n |
2434 | | #undef i18nc |
2435 | | #undef i18np |
2436 | | #undef i18ncp |
2437 | | #undef ki18n |
2438 | | #undef ki18nc |
2439 | | #undef ki18np |
2440 | | #undef ki18ncp |
2441 | | #undef tr2i18n |
2442 | | #undef xi18n |
2443 | | #undef xi18nc |
2444 | | #undef xi18np |
2445 | | #undef xi18ncp |
2446 | | #undef kxi18n |
2447 | | #undef kxi18nc |
2448 | | #undef kxi18np |
2449 | | #undef kxi18ncp |
2450 | | #undef tr2xi18n |
2451 | | #endif |
2452 | | |
2453 | | #endif // Q_QDOC |