src/pyams_template/metadirectives.py
changeset 15 c3d0112a61f6
parent 0 31ded33115d7
--- a/src/pyams_template/metadirectives.py	Mon Nov 25 15:46:23 2019 +0100
+++ b/src/pyams_template/metadirectives.py	Tue Nov 26 10:01:36 2019 +0100
@@ -10,19 +10,20 @@
 # FOR A PARTICULAR PURPOSE.
 #
 
-__docformat__ = 'restructuredtext'
+"""PyAMS_template.metadirectives module
+
+This module provides ZCML directives interfaces
+"""
+
+from pyramid.interfaces import IRequest
+from zope.configuration.fields import GlobalInterface, GlobalObject, Path
+from zope.interface import Interface
+from zope.schema import ASCIILine, TextLine
+
+from pyams_template.interfaces import IContentTemplate, ILayoutTemplate
 
 
-# import standard library
-
-# import interfaces
-from pyramid.interfaces import IRequest
-
-# import packages
-from zope.configuration.fields import Path, GlobalObject, GlobalInterface
-from zope.interface import Interface
-from zope.schema import TextLine, ASCIILine
-from pyams_template.interfaces import IContentTemplate, ILayoutTemplate
+__docformat__ = 'restructuredtext'
 
 
 class ITemplateDirective(Interface):
@@ -39,14 +40,11 @@
                     required=False)
 
     macro = TextLine(title='Macro',
-                     description="""
-                         The macro to be used.
-                         This allows us to define different macros in one template.
-                         The template designer can now create a whole site, the
-                         ViewTemplate can then extract the macros for single viewlets
-                         or views.
-                         If no macro is given the whole template is used for rendering.
-                         """,
+                     description="The macro to be used. This allows us to define different macros "
+                                 "in one template. The template designer can now create a whole "
+                                 "site, the ViewTemplate can then extract the macros for single "
+                                 "viewlets or views. If no macro is given the whole template is "
+                                 "used for rendering.",
                      default='',
                      required=False)
 
@@ -70,10 +68,10 @@
                                default=IContentTemplate,
                                required=False)
 
-    contentType = ASCIILine(title='Content Type',
-                            description='The content type identifies the type of data.',
-                            default='text/html',
-                            required=False)
+    content_type = ASCIILine(title='Content Type',
+                             description='The content type identifies the type of data.',
+                             default='text/html',
+                             required=False)
 
 
 class ILayoutTemplateDirective(ITemplateDirective):