Luke Stebbing  committed 46b5266

Tweak docstrings based on Mike's suggestions.

  • Participants
  • Parent commits 2173377
  • Branches trunk

Comments (0)

Files changed (2)

File webhelpers/

 def choose_height(new_width, width, height):
     """Return the height corresponding to ``new_width`` that's proportional
-       to the original size (``width * height``).
+       to the original size (``width`` x ``height``).
     proportion = float(height) / float(width)
     return int(new_width * proportion)
     or is not in a format recognized by PIL.
     Depends on the `Python Imaging Library
-    <>`_. See ``get_dimensions()`` if your
-    application is not otherwise using PIL.
+    <>`_. If your application is not
+    otherwise using PIL, see the ``get_dimensions()`` function, which does
+    not have external dependencies.
     import Image

File webhelpers/

     def add_alias(cls, alias, mimetype):
         """Create a MIMEType alias to a full mimetype.
-        Examples: ``('html', 'text/html')``, ``('xml', 'application/xml')``.
+        Examples:
-        An ``alias`` may not contain a ``/`` character.
+        - ``add_alias('html', 'text/html')``
+        - ``add_alias('xml', 'application/xml')``
+        An ``alias`` may not contain the ``/`` character.
         if '/' in alias: