[Zope3-checkins] CVS: Zope3/src/zope/i18n/interfaces -
__init__.py:1.6 locales.py:1.2
Stephan Richter
srichter at cosmos.phy.tufts.edu
Sat Apr 24 19:18:00 EDT 2004
Update of /cvs-repository/Zope3/src/zope/i18n/interfaces
In directory cvs.zope.org:/tmp/cvs-serv29065/src/zope/i18n/interfaces
Modified Files:
__init__.py locales.py
Log Message:
Interchanged PerissionField and InterfaceField with Choice and Sequence.
=== Zope3/src/zope/i18n/interfaces/__init__.py 1.5 => 1.6 ===
--- Zope3/src/zope/i18n/interfaces/__init__.py:1.5 Mon Mar 8 18:36:00 2004
+++ Zope3/src/zope/i18n/interfaces/__init__.py Sat Apr 24 19:17:59 2004
@@ -16,7 +16,7 @@
$Id$
"""
from zope.interface import Interface, Attribute
-from zope.schema import TextLine, Dict, EnumeratedTextLine
+from zope.schema import TextLine, Dict, Choice
class II18nAware(Interface):
@@ -332,12 +332,12 @@
symbols = Dict(
title=u"Number Symbols",
- key_type=EnumeratedTextLine(
+ key_type=Choice(
title=u"Dictionary Class",
- allowed_values=(u'decimal', u'group', u'list', u'percentSign',
- u'nativeZeroDigit', u'patternDigit', u'plusSign',
- u'minusSign', u'exponential', u'perMille',
- u'infinity', u'nan')),
+ values=(u'decimal', u'group', u'list', u'percentSign',
+ u'nativeZeroDigit', u'patternDigit', u'plusSign',
+ u'minusSign', u'exponential', u'perMille',
+ u'infinity', u'nan')),
value_type=TextLine(title=u"Symbol"))
=== Zope3/src/zope/i18n/interfaces/locales.py 1.1 => 1.2 ===
--- Zope3/src/zope/i18n/interfaces/locales.py:1.1 Thu Feb 5 17:52:22 2004
+++ Zope3/src/zope/i18n/interfaces/locales.py Sat Apr 24 19:18:00 2004
@@ -19,7 +19,7 @@
from zope.interface import Interface, Attribute
from zope.schema import \
Field, Text, TextLine, Int, Bool, Tuple, List, Dict, Date
-from zope.schema import Container, EnumeratedTextLine
+from zope.schema import Container, Choice
class ILocaleProvider(Interface):
"""This interface is our connection to the Zope 3 service. From it
@@ -192,9 +192,9 @@
names = Dict(
title = u"Time Zone Names",
description = u"Various names of the timezone.",
- key_type = EnumeratedTextLine(
+ key_type = Choice(
title = u"Time Zone Name Type",
- allowed_values = (u'generic', u'standard', u'daylight')),
+ values = (u'generic', u'standard', u'daylight')),
value_type = Tuple(title=u"Time Zone Name and Abbreviation",
min_length=2, max_length=2),
required = True,
@@ -226,10 +226,10 @@
class ILocaleFormatLength(Interface):
"""The format length describes a class of formats."""
- type = EnumeratedTextLine(
+ type = Choice(
title = u"Format Length Type",
description = u"Name of the format length",
- allowed_values = (u'full', u'long', u'medium', u'short')
+ values = (u'full', u'long', u'medium', u'short')
)
default = TextLine(
@@ -265,16 +265,16 @@
days = Dict(
title=u"Weekdays Names",
description = u"A mapping of all month names and abbreviations",
- key_type = EnumeratedTextLine(title=u"Type",
- allowed_values=(u'sun', u'mon', u'tue', u'wed',
- u'thu', u'fri', u'sat', u'sun')),
+ key_type = Choice(title=u"Type",
+ values=(u'sun', u'mon', u'tue', u'wed',
+ u'thu', u'fri', u'sat')),
value_type = Tuple(title=u"Weekdays Name and Abbreviation",
min_length=2, max_length=2))
week = Dict(
title=u"Week Information",
description = u"Contains various week information",
- key_type = EnumeratedTextLine(
+ key_type = Choice(
title=u"Type",
description=u"""
Varies Week information:
@@ -286,7 +286,7 @@
- The 'weekendStart' and 'weekendEnd' are tuples of the form
(weekDayNumber, datetime.time)
""",
- allowed_values=(u'minDays', u'firstDay',
+ values=(u'minDays', u'firstDay',
u'weekendStart', u'weekendEnd')))
am = TextLine(title=u"AM String")
@@ -304,10 +304,10 @@
dateFormats = Dict(
title=u"Date Formats",
description = u"Contains various Date Formats.",
- key_type = EnumeratedTextLine(
+ key_type = Choice(
title=u"Type",
description = u"Name of the format length",
- allowed_values = (u'full', u'long', u'medium', u'short')),
+ values = (u'full', u'long', u'medium', u'short')),
value_type = Field(title=u"ILocaleFormatLength object"))
defaultTimeFormat = TextLine(title=u"Default Time Format Type")
@@ -315,10 +315,10 @@
timeFormats = Dict(
title=u"Time Formats",
description = u"Contains various Time Formats.",
- key_type = EnumeratedTextLine(
+ key_type = Choice(
title=u"Type",
description = u"Name of the format length",
- allowed_values = (u'full', u'long', u'medium', u'short')),
+ values = (u'full', u'long', u'medium', u'short')),
value_type = Field(title=u"ILocaleFormatLength object"))
defaultDateTimeFormat = TextLine(title=u"Default Date-Time Format Type")
@@ -326,10 +326,10 @@
dateTimeFormats = Dict(
title=u"Date-Time Formats",
description = u"Contains various Date-Time Formats.",
- key_type = EnumeratedTextLine(
+ key_type = Choice(
title=u"Type",
description = u"Name of the format length",
- allowed_values = (u'full', u'long', u'medium', u'short')),
+ values = (u'full', u'long', u'medium', u'short')),
value_type = Field(title=u"ILocaleFormatLength object"))
def getMonthNames():
@@ -372,9 +372,9 @@
calendars = Dict(
title = u"Calendar type to ILocaleCalendar",
- key_type = EnumeratedTextLine(
+ key_type = Choice(
title=u"Calendar Type",
- allowed_values=(u'gregorian',
+ values=(u'gregorian',
u'arabic',
u'chinese',
u'civil-arabic',
@@ -409,9 +409,9 @@
symbols = Dict(
title = u"Number Symbols",
- key_type = EnumeratedTextLine(
+ key_type = Choice(
title = u"Format Name",
- allowed_values = (u'decimal', u'group', u'list', u'percentSign',
+ values = (u'decimal', u'group', u'list', u'percentSign',
u'nativeZeroDigit', u'patternDigit', u'plusSign',
u'minusSign', u'exponential', u'perMille',
u'infinity', u'nan')),
@@ -422,10 +422,10 @@
decimalFormats = Dict(
title=u"Decimal Formats",
description = u"Contains various Decimal Formats.",
- key_type = EnumeratedTextLine(
+ key_type = Choice(
title=u"Type",
description = u"Name of the format length",
- allowed_values = (u'full', u'long', u'medium', u'short')),
+ values = (u'full', u'long', u'medium', u'short')),
value_type = Field(title=u"ILocaleFormatLength object"))
defaultScientificFormat = TextLine(title=u"Default Scientific Format Type")
@@ -433,10 +433,10 @@
scientificFormats = Dict(
title=u"Scientific Formats",
description = u"Contains various Scientific Formats.",
- key_type = EnumeratedTextLine(
+ key_type = Choice(
title=u"Type",
description = u"Name of the format length",
- allowed_values = (u'full', u'long', u'medium', u'short')),
+ values = (u'full', u'long', u'medium', u'short')),
value_type = Field(title=u"ILocaleFormatLength object"))
defaultPercentFormat = TextLine(title=u"Default Percent Format Type")
@@ -444,10 +444,10 @@
percentFormats = Dict(
title=u"Percent Formats",
description = u"Contains various Percent Formats.",
- key_type = EnumeratedTextLine(
+ key_type = Choice(
title=u"Type",
description = u"Name of the format length",
- allowed_values = (u'full', u'long', u'medium', u'short')),
+ values = (u'full', u'long', u'medium', u'short')),
value_type = Field(title=u"ILocaleFormatLength object"))
defaultCurrencyFormat = TextLine(title=u"Default Currency Format Type")
@@ -455,10 +455,10 @@
currencyFormats = Dict(
title=u"Currency Formats",
description = u"Contains various Currency Formats.",
- key_type = EnumeratedTextLine(
+ key_type = Choice(
title=u"Type",
description = u"Name of the format length",
- allowed_values = (u'full', u'long', u'medium', u'short')),
+ values = (u'full', u'long', u'medium', u'short')),
value_type = Field(title=u"ILocaleFormatLength object"))
currencies = Dict(
@@ -525,10 +525,10 @@
delimiters = Dict(
title=u"Delimiters",
description = u"Contains various Currency data.",
- key_type = EnumeratedTextLine(
+ key_type = Choice(
title=u"Delimiter Type",
description = u"Delimiter name.",
- allowed_values=(u'quotationStart', u'quotationEnd',
+ values=(u'quotationStart', u'quotationEnd',
u'alternateQuotationStart',
u'alternateQuotationEnd')),
value_type = Field(title=u"Delimiter symbol"))
More information about the Zope3-Checkins
mailing list