Index: /main/waeup.kofa/trunk/src/waeup/kofa/schema/field.py
===================================================================
--- /main/waeup.kofa/trunk/src/waeup/kofa/schema/field.py	(revision 8145)
+++ /main/waeup.kofa/trunk/src/waeup/kofa/schema/field.py	(revision 8146)
@@ -19,9 +19,10 @@
 """
 from zope.interface import implements
-from zope.schema import TextLine
+from zope.schema import TextLine, Date
 from zope.schema.interfaces import (
     ITextLine, IBaseVocabulary, ISource, IContextSourceBinder, InvalidValue,)
 from zope.schema.vocabulary import (
     SimpleVocabulary, getVocabularyRegistry, VocabularyRegistryError)
+from waeup.kofa.schema.interfaces import IFormattedDate
 
 class CustomizableErrorMsg(object):
@@ -125,2 +126,28 @@
             raise InvalidValue(value)
         return
+
+class FormattedDate(Date):
+    """A date field that supports additional formatting attributes.
+
+    Stores extra attributes (see below). To make use of these
+    attributes in forms, you have to provide widgets that read them
+    and use them in their operations, for instance the
+    `waeup.kofa.widgets.datewidget.FormattedDateWidget`.
+
+    Extra attributes are as follows:
+
+    `date_format`
+      additional attribute to describe desired date format. Must be a
+      string that can be fed to strftime/strptime functions.
+
+    `show_year`
+      boolean indicating whether some kind of year selection should
+      be used with this instance.
+    """
+    implements(IFormattedDate)
+    date_format = '%Y-%m-%d'
+    show_year = False
+    def __init__(self, date_format='%Y-%m-%d', show_year=False, *args, **kw):
+        self.date_format = date_format
+        self.show_year = show_year
+        return super(FormattedDate, self).__init__(*args, **kw)
Index: /main/waeup.kofa/trunk/src/waeup/kofa/schema/interfaces.py
===================================================================
--- /main/waeup.kofa/trunk/src/waeup/kofa/schema/interfaces.py	(revision 8146)
+++ /main/waeup.kofa/trunk/src/waeup/kofa/schema/interfaces.py	(revision 8146)
@@ -0,0 +1,38 @@
+## $Id$
+##
+## Copyright (C) 2012 Uli Fouquet & Henrik Bettermann
+## This program is free software; you can redistribute it and/or modify
+## it under the terms of the GNU General Public License as published by
+## the Free Software Foundation; either version 2 of the License, or
+## (at your option) any later version.
+##
+## This program is distributed in the hope that it will be useful,
+## but WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+## GNU General Public License for more details.
+##
+## You should have received a copy of the GNU General Public License
+## along with this program; if not, write to the Free Software
+## Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+##
+from zope import schema
+from zope.schema.interfaces import IDate
+
+class IFormattedDate(IDate):
+    """A formatted date.
+
+    Basically a zope.schema.IDate, but with optional additional
+    attributes. These attributes _can_ be used by widgets to change
+    the way of editing or displaying a date.
+
+    The waeup.kofa.widgets.datewidget.FormattedDateWidget is a widget
+    that supports these additional attributes.
+    """
+    show_year = schema.Bool(
+        title = u'Show year selector when editing this date?',
+        default = False,
+        )
+    date_format = schema.ASCII(
+        title = u'A date format string suitable for use with strftime.',
+        default = '%Y-%m-%d',
+        )
Index: /main/waeup.kofa/trunk/src/waeup/kofa/schema/tests/test_fields.py
===================================================================
--- /main/waeup.kofa/trunk/src/waeup/kofa/schema/tests/test_fields.py	(revision 8146)
+++ /main/waeup.kofa/trunk/src/waeup/kofa/schema/tests/test_fields.py	(revision 8146)
@@ -0,0 +1,33 @@
+"""Tests for waeup.kofa.schema fields.
+"""
+import unittest
+from zope.interface.verify import verifyClass, verifyObject
+from zope.schema.interfaces import IDate
+from waeup.kofa.schema import FormattedDate
+from waeup.kofa.schema.interfaces import IFormattedDate
+
+class FormattedDateTests(unittest.TestCase):
+    # Tests for FormattedDate field.
+
+    def test_iface(self):
+        # make sure we fullfill interface contracts
+        obj = FormattedDate()
+        verifyClass(IDate, FormattedDate)
+        verifyClass(IFormattedDate, FormattedDate)
+        verifyObject(IDate, obj)
+        verifyObject(IFormattedDate, obj)
+        return
+
+    def test_defaults(self):
+        # we get expected default values for dates.
+        obj = FormattedDate()
+        self.assertEqual(obj.show_year, False)
+        self.assertEqual(obj.date_format, '%Y-%m-%d')
+        return
+
+    def test_attribs(self):
+        # we can set the promised attributes.
+        obj = FormattedDate(show_year=True, date_format='%d.%m.%Y')
+        self.assertEqual(obj.show_year, True)
+        self.assertEqual(obj.date_format, '%d.%m.%Y')
+        return
