Permalink
Browse files

Added docs for AreaWidget.

  • Loading branch information...
1 parent 58f50d5 commit 49052928cd7d4235af9de0b75965aabab43a33ec @melinath melinath committed Mar 7, 2013
Showing with 20 additions and 0 deletions.
  1. +20 −0 docs/guides/using-daguerre.rst
@@ -142,3 +142,23 @@ The syntax is similar to :ttag:`{% adjust %}`, except that:
item in the iterable (``"method.image"``) are provided in place
of an image file or storage path.
* :ttag:`{% adjust_bulk %}` **doesn't support named crops**.
+
+Editing Areas
++++++++++++++
+
+Daguerre provides a widget which can be used with any
+:class:`ImageField` to edit :class:`Areas <.Area>` for that image file.
+Using this widget with a :class:`ModelAdmin` is as simple as defining
+appropriate `formfield_overrides`_.
+
+.. code-block:: python
+
+ from daguerre.widgets import AreaWidget
+
+ class YourModelAdmin(admin.ModelAdmin):
+ formfield_overrides = {
+ models.ImageField: {'widget': AreaWidget},
+ }
+ ...
+
+.. _formfield_overrides: https://docs.djangoproject.com/en/dev/ref/contrib/admin/#django.contrib.admin.ModelAdmin.formfield_overrides

0 comments on commit 4905292

Please sign in to comment.