Skip to content

Commit f9c2838

Browse files
author
Ryan P Kilby
committed
Small doc style fixes
1 parent 9fb50e5 commit f9c2838

File tree

3 files changed

+10
-4
lines changed

3 files changed

+10
-4
lines changed

docs/ref/fields.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,9 @@ Defines a class level attribute ``ISO_8601`` as constant for the format.
1111

1212
Sets ``input_formats = [ISO_8601]`` — this means that by default ``IsoDateTimeField`` will **only** parse ISO 8601 formated dates.
1313

14-
You may set ``input_formats`` to your list of required formats as per the `DateTimeField Docs`_, using the ``ISO_8601`` class level attribute to specify the ISO 8601 format. ::
14+
You may set ``input_formats`` to your list of required formats as per the `DateTimeField Docs`_, using the ``ISO_8601`` class level attribute to specify the ISO 8601 format.
15+
16+
.. code-block:: python
1517

1618
f = IsoDateTimeField()
1719
f.input_formats = [IsoDateTimeField.ISO_8601] + DateTimeField.input_formats

docs/ref/settings.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,6 @@ For example, you could add verbose output for "exact" lookups.
9292
FILTERS_STRICTNESS
9393
------------------
9494

95-
DEFAULT: ``STRICTNESS.RETURN_NO_RESULTS``
95+
Default: ``STRICTNESS.RETURN_NO_RESULTS``
9696

9797
Set the global default for FilterSet :ref:`strictness <strict>`.

docs/ref/widgets.txt

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,9 @@ placeholders:
3030

3131
This widget converts its input into Python's True/False values. It will convert
3232
all case variations of ``True`` and ``False`` into the internal Python values.
33-
To use it, pass this into the ``widgets`` argument of the ``BooleanFilter``::
33+
To use it, pass this into the ``widgets`` argument of the ``BooleanFilter``:
34+
35+
.. code-block:: python
3436

3537
active = BooleanFilter(widget=BooleanWidget())
3638

@@ -54,6 +56,8 @@ This widget is used with ``RangeFilter`` and its subclasses. It generates two
5456
form input elements which generally act as start/end values in a range.
5557
Under the hood, it is django's ``forms.TextInput`` widget and excepts
5658
the same arguments and values. To use it, pass it to ``widget`` argument of
57-
a ``RangeField``::
59+
a ``RangeField``:
60+
61+
.. code-block:: python
5862

5963
date_range = DateFromToRangeFilter(widget=RangeWidget(attrs={'placeholder': 'YYYY/MM/DD'}))

0 commit comments

Comments
 (0)