added plural rules again
This commit is contained in:
@@ -1 +1 @@
|
||||
Version 2.0.3 (2012-08-31 00:11:28) stable
|
||||
Version 2.0.3 (2012-08-31 00:29:05) stable
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for af (Afrikaans (South Africa))
|
||||
|
||||
nplurals=2 # Afrikaans language has 2 forms:
|
||||
# 1 singular and 1 plural
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: int(n != 1)
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: (word + 'suffix')
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for bg (Bulgarian)
|
||||
|
||||
nplurals=2 # Bulgarian language has 2 forms:
|
||||
# 1 singular and 1 plural
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: int(n != 1)
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: (word + 'suffix')
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for cs (Czech)
|
||||
|
||||
nplurals=3 # Czech language has 3 forms:
|
||||
# 1 singular and 2 plurals
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: ( 0 if n==1 else
|
||||
1 if 2<=n<=4 else
|
||||
2 )
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: (word + 'suffix')
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for de (Deutsch)
|
||||
|
||||
nplurals=2 # German language has 2 forms:
|
||||
# 1 singular and 1 plural
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: int(n != 1)
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: (word + 'suffix')
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for en (English)
|
||||
|
||||
nplurals=2 # English language has 2 forms:
|
||||
# 1 singular and 1 plural
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: int(n != 1)
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
construct_plural_form = lambda word, plural_id: (word +
|
||||
('es' if word[-1:] in ('s','x','o') or
|
||||
word[-2:] in ('sh','ch')
|
||||
else 's'))
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for es (Spanish)
|
||||
|
||||
nplurals=2 # Spanish language has 2 forms:
|
||||
# 1 singular and 1 plural
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: int(n != 1)
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: (word + 'suffix')
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for fr (French))
|
||||
|
||||
nplurals=2 # French language has 2 forms:
|
||||
# 1 singular and 1 plural
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: int(n != 1)
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: (word + 'suffix')
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for he (Hebrew)
|
||||
|
||||
nplurals=2 # Hebrew language has 2 forms:
|
||||
# 1 singular and 1 plural
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: int(n != 1)
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: (word + 'suffix')
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for he (Hindi)
|
||||
|
||||
nplurals=2 # Hindi has 2 forms:
|
||||
# 1 singular and 1 plural
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: int(n != 1)
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: (word + 'suffix')
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for hu (Hungarian)
|
||||
|
||||
nplurals=2 # Hungarian language has 2 forms:
|
||||
# 1 singular and 1 plural
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: int(n != 1)
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: (word + 'suffix')
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for it (Italian)
|
||||
|
||||
nplurals=2 # Italian language has 2 forms:
|
||||
# 1 singular and 1 plural
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: int(n != 1)
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: (word + 'suffix')
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for ja (Japanese)
|
||||
|
||||
nplurals=1 # Japanese language has ONE form!
|
||||
|
||||
# Always returns 0:
|
||||
get_plural_id = lambda n: 0
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: word
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for lt (Lithuanian)
|
||||
|
||||
nplurals=3 # Lithuanian language has 3 forms:
|
||||
# 1 singular and 2 plurals
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: (0 if n % 10 == 1 and n % 100 != 11 else
|
||||
1 if n % 10 >= 2 and (n % 100 < 10 or n % 100 >= 20) else
|
||||
2)
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: (word + 'suffix')
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for pl (Polish)
|
||||
|
||||
nplurals=3 # Polish language has 3 forms:
|
||||
# 1 singular and 2 plurals
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: (0 if n==1 else
|
||||
1 if 2<=n<=4 else
|
||||
2)
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: (word + 'suffix')
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for pt (Portuguese)
|
||||
|
||||
nplurals=2 # Portuguese has 2 forms:
|
||||
# 1 singular and 1 plural
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: int(n != 1)
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: (word + 'suffix')
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for ro (Romanian)
|
||||
|
||||
nplurals=2 # Romanian has 2 forms:
|
||||
# 1 singular and 1 plural
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: int(n != 1)
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: (word + 'suffix')
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for ru (Russian)
|
||||
|
||||
nplurals=3 # Russian language has 3 forms:
|
||||
# 1 singular and 2 plurals
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: (0 if n % 10 == 1 and n % 100 != 11 else
|
||||
1 if n % 10 >= 2 and n % 10 <= 4 and
|
||||
(n % 100 < 10 or n % 100 >= 20) else
|
||||
2)
|
||||
|
||||
# construct_plural_form() is not used now because of complex
|
||||
# rules of Russian language. Default version of
|
||||
# this function is used to simple insert new words into
|
||||
# plural_dict dictionary)
|
||||
# construct_plural_form = lambda word, plural_id: word
|
||||
@@ -0,0 +1,20 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for sk (Slovak (Slovakia))
|
||||
|
||||
nplurals=3 # Slovak language has 3 forms:
|
||||
# 1 singular and 2 plurals
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: (0 if n % 10 == 1 and n % 100 != 11 else
|
||||
1 if n % 10 >= 2 and n % 10 <= 4 and
|
||||
(n % 100 < 10 or n % 100 >= 20) else
|
||||
2)
|
||||
|
||||
# construct_plural_form() is not used now because of complex
|
||||
# rules of Slovak language. Default version of this function
|
||||
# is used to simple insert new words into plural_dict dictionary)
|
||||
# construct_plural_form = lambda word, plural_id: word
|
||||
|
||||
@@ -0,0 +1,20 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for sl (Slovenian)
|
||||
|
||||
nplurals=4 # Slovenian language has 4 forms:
|
||||
# 1 singular and 3 plurals
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: (0 if n % 100 == 1 else
|
||||
1 if n % 100 == 2 else
|
||||
2 if n % 100 in (3,4) else
|
||||
3)
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: (word + 'suffix')
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for tr (Turkish)
|
||||
|
||||
nplurals=1 # Turkish language has ONE form!
|
||||
|
||||
# Always returns 0:
|
||||
get_plural_id = lambda n: 0
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: word
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for uk (Ukrainian)
|
||||
|
||||
nplurals=3 # Ukrainian language has 3 forms:
|
||||
# 1 singular and 2 plurals
|
||||
|
||||
# Determine plural_id for number *n* as sequence of positive
|
||||
# integers: 0,1,...
|
||||
# NOTE! For singular form ALWAYS return plural_id = 0
|
||||
get_plural_id = lambda n: (0 if n % 10 == 1 and n % 100 != 11 else
|
||||
1 if n % 10 >= 2 and n % 10 <= 4 and
|
||||
(n % 100 < 10 or n % 100 >= 20) else
|
||||
2)
|
||||
|
||||
# construct_plural_form() is not used now because of complex
|
||||
# rules of Ukrainian language. Default version of
|
||||
# this function is used to simple insert new words into
|
||||
# plural_dict dictionary)
|
||||
# construct_plural_form = lambda word, plural_id: word
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf8 -*-
|
||||
# Plural-Forms for zh (Chinese)
|
||||
|
||||
nplurals=1 # Chinese language has ONE form!
|
||||
|
||||
# Always returns 0:
|
||||
get_plural_id = lambda n: 0
|
||||
|
||||
# Construct and return plural form of *word* using
|
||||
# *plural_id* (which ALWAYS>0). This function will be executed
|
||||
# for words (or phrases) not found in plural_dict dictionary
|
||||
# construct_plural_form = lambda word, plural_id: word
|
||||
|
||||
Reference in New Issue
Block a user