1
0
Fork 0
mirror of git://git.gnupg.org/gnupg.git synced 2025-07-03 22:56:33 +02:00

UTF-8 Fixes

This commit is contained in:
Werner Koch 2007-05-04 09:22:18 +00:00
parent 3bcccb1666
commit 3c351d0232
7 changed files with 62 additions and 16 deletions

View file

@ -1,3 +1,8 @@
2007-04-25 Werner Koch <wk@g10code.com>
* i18n.h (ngettext): New.
* simple-gettext.c (ngettext): New.
2007-04-20 Werner Koch <wk@g10code.com>
* miscellaneous.c (my_gcry_logger, my_gcry_outofcore_handler):

View file

@ -17,6 +17,8 @@
#ifdef USE_SIMPLE_GETTEXT
int set_gettext_file( const char *filename );
const char *gettext( const char *msgid );
const char *ngettext(const char *msgid1, const char *msgid2,
unsigned long int n);
# define _(a) gettext (a)
# define N_(a) (a)
#else
@ -34,6 +36,7 @@
# else
# define _(a) (a)
# define N_(a) (a)
# define ngettext(a,b,c) ((c)==1? (a):(b))
# endif
#endif /*!USE_SIMPLE_GETTEXT*/

View file

@ -419,6 +419,15 @@ gettext( const char *msgid )
return msgid;
}
const char *
ngettext (const char *msgid1, const char *msgid2, unsigned long int n)
{
/* We use the simple Germanic plural rule. */
return gettext (n==1? msgid1 : msgid2);
}
#if 0
unsigned int cp1, cp2;