diff options
| author | rowanv <rrvspam@gmail.com> | 2016-01-24 22:26:11 +0100 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2016-02-01 10:42:05 -0500 |
| commit | a6ef025dfb2a1d1bd23893408eef6d066fb506d9 (patch) | |
| tree | b29b3624a20cc65184c743102e0f5f620412105f /docs/ref/contrib | |
| parent | 8bf8d0e0ecc1805480deb94feb4675b09d3b3a95 (diff) | |
Fixed #26124 -- Added missing code formatting to docs headers.
Diffstat (limited to 'docs/ref/contrib')
22 files changed, 345 insertions, 339 deletions
diff --git a/docs/ref/contrib/admin/index.txt b/docs/ref/contrib/admin/index.txt index 5e347fb9fb..e1facc2a5a 100644 --- a/docs/ref/contrib/admin/index.txt +++ b/docs/ref/contrib/admin/index.txt @@ -101,8 +101,8 @@ Other topics admin.site.register(Author) -The register decorator ----------------------- +The ``register`` decorator +-------------------------- .. function:: register(*models, site=django.admin.sites.site) diff --git a/docs/ref/contrib/auth.txt b/docs/ref/contrib/auth.txt index 66906d5ddc..778fb10b3e 100644 --- a/docs/ref/contrib/auth.txt +++ b/docs/ref/contrib/auth.txt @@ -9,8 +9,8 @@ topic guide </topics/auth/index>`. .. currentmodule:: django.contrib.auth -User -==== +``User`` model +============== Fields ------ @@ -262,8 +262,8 @@ Manager methods :attr:`~models.User.is_superuser` to ``True``. -Anonymous users -=============== +``AnonymousUser`` object +======================== .. class:: models.AnonymousUser @@ -296,8 +296,8 @@ In practice, you probably won't need to use :class:`~django.contrib.auth.models.AnonymousUser` objects on your own, but they're used by Web requests, as explained in the next section. -Permission -========== +``Permission`` model +==================== .. class:: models.Permission @@ -328,8 +328,8 @@ Methods :class:`~django.contrib.auth.models.Permission` objects have the standard data-access methods like any other :doc:`Django model </ref/models/instances>`. -Group -===== +``Group`` model +=============== .. class:: models.Group diff --git a/docs/ref/contrib/gis/commands.txt b/docs/ref/contrib/gis/commands.txt index 71f3863f4b..719edac03e 100644 --- a/docs/ref/contrib/gis/commands.txt +++ b/docs/ref/contrib/gis/commands.txt @@ -2,8 +2,8 @@ GeoDjango Management Commands ============================= -inspectdb -========= +``inspectdb`` +============= .. describe:: django-admin inspectdb @@ -12,8 +12,8 @@ When :mod:`django.contrib.gis` is in your :setting:`INSTALLED_APPS`, the The overridden command is spatially-aware, and places geometry fields in the auto-generated model definition, where appropriate. -ogrinspect -========== +``ogrinspect`` +============== .. django-admin:: ogrinspect data_source model_name diff --git a/docs/ref/contrib/gis/functions.txt b/docs/ref/contrib/gis/functions.txt index 282fe55a38..04da9e78af 100644 --- a/docs/ref/contrib/gis/functions.txt +++ b/docs/ref/contrib/gis/functions.txt @@ -35,8 +35,8 @@ Measurement Relationships Operations Editors :class:`Translate` ================== ======================= ====================== =================== ================== ===================== -Area -==== +``Area`` +======== .. class:: Area(expression, **extra) @@ -47,8 +47,8 @@ field as an :class:`~django.contrib.gis.measure.Area` measure. On MySQL, a raw float value is returned, as it's not possible to automatically determine the unit of the field. -AsGeoJSON -========= +``AsGeoJSON`` +============= .. class:: AsGeoJSON(expression, bbox=False, crs=False, precision=8, **extra) @@ -79,8 +79,8 @@ Keyword Argument Description representation -- the default value is 8. ===================== ===================================================== -AsGML -===== +``AsGML`` +========= .. class:: AsGML(expression, version=2, precision=8, **extra) @@ -110,8 +110,8 @@ Keyword Argument Description __ https://en.wikipedia.org/wiki/Geography_Markup_Language -AsKML -===== +``AsKML`` +========= .. class:: AsKML(expression, precision=8, **extra) @@ -137,8 +137,8 @@ Keyword Argument Description __ https://developers.google.com/kml/documentation/ -AsSVG -===== +``AsSVG`` +========= .. class:: AsSVG(expression, relative=False, precision=8, **extra) @@ -161,8 +161,8 @@ Keyword Argument Description __ http://www.w3.org/Graphics/SVG/ -BoundingCircle -============== +``BoundingCircle`` +================== .. class:: BoundingCircle(expression, num_seg=48, **extra) @@ -171,8 +171,8 @@ BoundingCircle Accepts a single geographic field or expression and returns the smallest circle polygon that can fully contain the geometry. -Centroid -======== +``Centroid`` +============ .. class:: Centroid(expression, **extra) @@ -181,8 +181,8 @@ Centroid Accepts a single geographic field or expression and returns the ``centroid`` value of the geometry. -Difference -========== +``Difference`` +============== .. class:: Difference(expr1, expr2, **extra) @@ -196,8 +196,8 @@ geometry B. MySQL support was added. -Distance -======== +``Distance`` +============ .. class:: Distance(expr1, expr2, spheroid=None, **extra) @@ -240,8 +240,8 @@ queryset is calculated:: in kilometers. See :doc:`measure` for usage details and the list of :ref:`supported_units`. -Envelope -======== +``Envelope`` +============ .. class:: Envelope(expression, **extra) @@ -250,8 +250,8 @@ Envelope Accepts a single geographic field or expression and returns the geometry representing the bounding box of the geometry. -ForceRHR -======== +``ForceRHR`` +============ .. class:: ForceRHR(expression, **extra) @@ -261,8 +261,8 @@ Accepts a single geographic field or expression and returns a modified version of the polygon/multipolygon in which all of the vertices follow the right-hand rule. -GeoHash -======= +``GeoHash`` +=========== .. class:: GeoHash(expression, **extra) @@ -277,8 +277,8 @@ representation of the geometry. __ https://en.wikipedia.org/wiki/Geohash -Intersection -============ +``Intersection`` +================ .. class:: Intersection(expr1, expr2, **extra) @@ -291,8 +291,8 @@ intersection between them. MySQL support was added. -Length -====== +``Length`` +========== .. class:: Length(expression, spheroid=True, **extra) @@ -308,8 +308,8 @@ specify if the calculation should be based on a simple sphere (less accurate, less resource-intensive) or on a spheroid (more accurate, more resource-intensive) with the ``spheroid`` keyword argument. -MemSize -======= +``MemSize`` +=========== .. class:: MemSize(expression, **extra) @@ -318,8 +318,8 @@ MemSize Accepts a single geographic field or expression and returns the memory size (number of bytes) that the geometry field takes. -NumGeometries -============= +``NumGeometries`` +================= .. class:: NumGeometries(expression, **extra) @@ -329,8 +329,8 @@ Accepts a single geographic field or expression and returns the number of geometries if the geometry field is a collection (e.g., a ``GEOMETRYCOLLECTION`` or ``MULTI*`` field); otherwise returns ``None``. -NumPoints -========= +``NumPoints`` +============= .. class:: NumPoints(expression, **extra) @@ -339,8 +339,8 @@ NumPoints Accepts a single geographic field or expression and returns the number of points in the first linestring in the geometry field; otherwise returns ``None``. -Perimeter -========= +``Perimeter`` +============= .. class:: Perimeter(expression, **extra) @@ -351,8 +351,8 @@ geometry field as a :class:`~django.contrib.gis.measure.Distance` object. On MySQL, a raw float value is returned, as it's not possible to automatically determine the unit of the field. -PointOnSurface -============== +``PointOnSurface`` +================== .. class:: PointOnSurface(expression, **extra) @@ -361,8 +361,8 @@ PointOnSurface Accepts a single geographic field or expression and returns a ``Point`` geometry guaranteed to lie on the surface of the field; otherwise returns ``None``. -Reverse -======= +``Reverse`` +=========== .. class:: Reverse(expression, **extra) @@ -371,8 +371,8 @@ Reverse Accepts a single geographic field or expression and returns a geometry with reversed coordinates. -Scale -===== +``Scale`` +========= .. class:: Scale(expression, x, y, z=0.0, **extra) @@ -382,8 +382,8 @@ Accepts a single geographic field or expression and returns a geometry with scaled coordinates by multiplying them with the ``x``, ``y``, and optionally ``z`` parameters. -SnapToGrid -========== +``SnapToGrid`` +============== .. class:: SnapToGrid(expression, *args, **extra) @@ -402,8 +402,8 @@ Number of Arguments Description 4 X, Y sizes and the corresponding X, Y origins. =================== ===================================================== -SymDifference -============= +``SymDifference`` +================= .. class:: SymDifference(expr1, expr2, **extra) @@ -417,8 +417,8 @@ parameters. MySQL support was added. -Transform -========= +``Transform`` +============= .. class:: Transform(expression, srid, **extra) @@ -434,8 +434,8 @@ the transformed geometry to the spatial reference system specified by the the spatial database used. In other words, the SRID numbers used for Oracle are not necessarily the same as those used by PostGIS. -Translate -========= +``Translate`` +============= .. class:: Translate(expression, x, y, z=0.0, **extra) @@ -445,8 +445,8 @@ Accepts a single geographic field or expression and returns a geometry with its coordinates offset by the ``x``, ``y``, and optionally ``z`` numeric parameters. -Union -===== +``Union`` +========= .. class:: Union(expr1, expr2, **extra) diff --git a/docs/ref/contrib/gis/gdal.txt b/docs/ref/contrib/gis/gdal.txt index 23728a354a..0d5af4aaca 100644 --- a/docs/ref/contrib/gis/gdal.txt +++ b/docs/ref/contrib/gis/gdal.txt @@ -1531,8 +1531,8 @@ Settings .. setting:: GDAL_LIBRARY_PATH -GDAL_LIBRARY_PATH ------------------ +``GDAL_LIBRARY_PATH`` +--------------------- A string specifying the location of the GDAL library. Typically, this setting is only used if the GDAL library is in a non-standard diff --git a/docs/ref/contrib/gis/geoip.txt b/docs/ref/contrib/gis/geoip.txt index f46770e5ea..58093dcdff 100644 --- a/docs/ref/contrib/gis/geoip.txt +++ b/docs/ref/contrib/gis/geoip.txt @@ -60,8 +60,8 @@ usage:: .. setting:: GEOIP_PATH -GEOIP_PATH ----------- +``GEOIP_PATH`` +-------------- A string specifying the directory where the GeoIP data files are located. This setting is *required* unless manually specified @@ -69,8 +69,8 @@ with ``path`` keyword when initializing the :class:`GeoIP` object. .. setting:: GEOIP_LIBRARY_PATH -GEOIP_LIBRARY_PATH ------------------- +``GEOIP_LIBRARY_PATH`` +---------------------- A string specifying the location of the GeoIP C library. Typically, this setting is only used if the GeoIP C library is in a non-standard @@ -78,16 +78,16 @@ location (e.g., ``/home/sue/lib/libGeoIP.so``). .. setting:: GEOIP_COUNTRY -GEOIP_COUNTRY -------------- +``GEOIP_COUNTRY`` +----------------- The basename to use for the GeoIP country data file. Defaults to ``'GeoIP.dat'``. .. setting:: GEOIP_CITY -GEOIP_CITY ----------- +``GEOIP_CITY`` +-------------- The basename to use for the GeoIP city data file. Defaults to ``'GeoLiteCity.dat'``. diff --git a/docs/ref/contrib/gis/geoip2.txt b/docs/ref/contrib/gis/geoip2.txt index 3471e9a0f6..8e51aa6fb5 100644 --- a/docs/ref/contrib/gis/geoip2.txt +++ b/docs/ref/contrib/gis/geoip2.txt @@ -54,8 +54,8 @@ Here is an example of its usage:: .. setting:: GEOIP_PATH -GEOIP_PATH ----------- +``GEOIP_PATH`` +-------------- A string specifying the directory where the GeoIP data files are located. This setting is *required* unless manually specified @@ -63,16 +63,16 @@ with ``path`` keyword when initializing the :class:`GeoIP2` object. .. setting:: GEOIP_COUNTRY -GEOIP_COUNTRY -------------- +``GEOIP_COUNTRY`` +----------------- The basename to use for the GeoIP country data file. Defaults to ``'GeoLite2-Country.mmdb'``. .. setting:: GEOIP_CITY -GEOIP_CITY ----------- +``GEOIP_CITY`` +-------------- The basename to use for the GeoIP city data file. Defaults to ``'GeoLite2-City.mmdb'``. diff --git a/docs/ref/contrib/gis/geoquerysets.txt b/docs/ref/contrib/gis/geoquerysets.txt index c3aae137c1..b694c6bdef 100644 --- a/docs/ref/contrib/gis/geoquerysets.txt +++ b/docs/ref/contrib/gis/geoquerysets.txt @@ -23,8 +23,8 @@ compatible with a particular spatial backend, refer to the .. fieldlookup:: bbcontains -bbcontains ----------- +``bbcontains`` +-------------- *Availability*: PostGIS, MySQL, SpatiaLite @@ -45,8 +45,8 @@ SpatiaLite ``MbrContains(poly, geom)`` .. fieldlookup:: bboverlaps -bboverlaps ----------- +``bboverlaps`` +-------------- *Availability*: PostGIS, MySQL, SpatiaLite @@ -67,8 +67,8 @@ SpatiaLite ``MbrOverlaps(poly, geom)`` .. fieldlookup:: contained -contained ---------- +``contained`` +------------- *Availability*: PostGIS, MySQL, SpatiaLite @@ -89,8 +89,8 @@ SpatiaLite ``MbrWithin(poly, geom)`` .. fieldlookup:: gis-contains -contains --------- +``contains`` +------------ *Availability*: PostGIS, Oracle, MySQL, SpatiaLite @@ -111,8 +111,8 @@ SpatiaLite ``Contains(poly, geom)`` .. fieldlookup:: contains_properly -contains_properly ------------------ +``contains_properly`` +--------------------- *Availability*: PostGIS @@ -131,8 +131,8 @@ PostGIS ``ST_ContainsProperly(poly, geom)`` .. fieldlookup:: coveredby -coveredby ---------- +``coveredby`` +------------- *Availability*: PostGIS, Oracle @@ -152,8 +152,8 @@ Oracle ``SDO_COVEREDBY(poly, geom)`` .. fieldlookup:: covers -covers ------- +``covers`` +---------- *Availability*: PostGIS, Oracle @@ -173,8 +173,8 @@ Oracle ``SDO_COVERS(poly, geom)`` .. fieldlookup:: crosses -crosses -------- +``crosses`` +----------- *Availability*: PostGIS, SpatiaLite @@ -193,8 +193,8 @@ SpatiaLite ``Crosses(poly, geom)`` .. fieldlookup:: disjoint -disjoint --------- +``disjoint`` +------------ *Availability*: PostGIS, Oracle, MySQL, SpatiaLite @@ -215,23 +215,23 @@ SpatiaLite ``Disjoint(poly, geom)`` .. fieldlookup:: equals -equals ------- +``equals`` +---------- *Availability*: PostGIS, Oracle, MySQL, SpatiaLite .. fieldlookup:: exact .. fieldlookup:: same_as -exact, same_as --------------- +``exact``, ``same_as`` +---------------------- *Availability*: PostGIS, Oracle, MySQL, SpatiaLite .. fieldlookup:: intersects -intersects ----------- +``intersects`` +-------------- *Availability*: PostGIS, Oracle, MySQL, SpatiaLite @@ -252,15 +252,15 @@ SpatiaLite ``Intersects(poly, geom)`` .. fieldlookup:: overlaps -overlaps --------- +``overlaps`` +------------ *Availability*: PostGIS, Oracle, MySQL, SpatiaLite .. fieldlookup:: relate -relate ------- +``relate`` +---------- *Availability*: PostGIS, Oracle, SpatiaLite @@ -311,8 +311,8 @@ Oracle SQL equivalent:: .. fieldlookup:: touches -touches -------- +``touches`` +----------- *Availability*: PostGIS, Oracle, MySQL, SpatiaLite @@ -333,8 +333,8 @@ SpatiaLite ``Touches(poly, geom)`` .. fieldlookup:: within -within ------- +``within`` +---------- *Availability*: PostGIS, Oracle, MySQL, SpatiaLite @@ -355,8 +355,8 @@ SpatiaLite ``Within(poly, geom)`` .. fieldlookup:: left -left ----- +``left`` +-------- *Availability*: PostGIS @@ -373,8 +373,8 @@ PostGIS equivalent:: .. fieldlookup:: right -right ------ +``right`` +--------- *Availability*: PostGIS @@ -391,8 +391,8 @@ PostGIS equivalent:: .. fieldlookup:: overlaps_left -overlaps_left -------------- +``overlaps_left`` +----------------- *Availability*: PostGIS @@ -410,8 +410,8 @@ PostGIS equivalent:: .. fieldlookup:: overlaps_right -overlaps_right --------------- +``overlaps_right`` +------------------ *Availability*: PostGIS @@ -428,8 +428,8 @@ PostGIS equivalent:: .. fieldlookup:: overlaps_above -overlaps_above --------------- +``overlaps_above`` +------------------ *Availability*: PostGIS @@ -446,8 +446,8 @@ PostGIS equivalent:: .. fieldlookup:: overlaps_below -overlaps_below --------------- +``overlaps_below`` +------------------ *Availability*: PostGIS @@ -464,8 +464,8 @@ PostGIS equivalent:: .. fieldlookup:: strictly_above -strictly_above --------------- +``strictly_above`` +------------------ *Availability*: PostGIS @@ -482,8 +482,8 @@ PostGIS equivalent:: .. fieldlookup:: strictly_below -strictly_below --------------- +``strictly_below`` +------------------ *Availability*: PostGIS @@ -532,8 +532,8 @@ function is used with projected coordinate systems. .. fieldlookup:: distance_gt -distance_gt ------------ +``distance_gt`` +--------------- Returns models where the distance to the geometry field from the lookup geometry is greater than the given distance value. @@ -552,8 +552,8 @@ SpatiaLite ``Distance(poly, geom) > 5`` .. fieldlookup:: distance_gte -distance_gte ------------- +``distance_gte`` +---------------- Returns models where the distance to the geometry field from the lookup geometry is greater than or equal to the given distance value. @@ -572,8 +572,8 @@ SpatiaLite ``Distance(poly, geom) >= 5`` .. fieldlookup:: distance_lt -distance_lt ------------ +``distance_lt`` +--------------- Returns models where the distance to the geometry field from the lookup geometry is less than the given distance value. @@ -592,8 +592,8 @@ SpatiaLite ``Distance(poly, geom) < 5`` .. fieldlookup:: distance_lte -distance_lte ------------- +``distance_lte`` +---------------- Returns models where the distance to the geometry field from the lookup geometry is less than or equal to the given distance value. @@ -612,8 +612,8 @@ SpatiaLite ``Distance(poly, geom) <= 5`` .. fieldlookup:: dwithin -dwithin -------- +``dwithin`` +----------- Returns models where the distance to the geometry field from the lookup geometry are within the given distance from one another. Note that you can only diff --git a/docs/ref/contrib/gis/geos.txt b/docs/ref/contrib/gis/geos.txt index 63de3cf6f3..206a24c8aa 100644 --- a/docs/ref/contrib/gis/geos.txt +++ b/docs/ref/contrib/gis/geos.txt @@ -1107,8 +1107,8 @@ Settings .. setting:: GEOS_LIBRARY_PATH -GEOS_LIBRARY_PATH ------------------ +``GEOS_LIBRARY_PATH`` +--------------------- A string specifying the location of the GEOS C library. Typically, this setting is only used if the GEOS C library is in a non-standard diff --git a/docs/ref/contrib/gis/serializers.txt b/docs/ref/contrib/gis/serializers.txt index 5226a9b9e8..96548d4635 100644 --- a/docs/ref/contrib/gis/serializers.txt +++ b/docs/ref/contrib/gis/serializers.txt @@ -1,6 +1,6 @@ -================== -GeoJSON Serializer -================== +====================== +``GeoJSON`` Serializer +====================== .. module:: django.contrib.gis.serializers.geojson :synopsis: Serialization of GeoDjango models in the GeoJSON format. diff --git a/docs/ref/contrib/humanize.txt b/docs/ref/contrib/humanize.txt index 66b15d70f3..0c0714f801 100644 --- a/docs/ref/contrib/humanize.txt +++ b/docs/ref/contrib/humanize.txt @@ -1,6 +1,6 @@ -======================== -django.contrib.humanize -======================== +=========================== +``django.contrib.humanize`` +=========================== .. module:: django.contrib.humanize :synopsis: A set of Django template filters useful for adding a "human @@ -15,8 +15,8 @@ filters. .. templatefilter:: apnumber -apnumber -======== +``apnumber`` +============ For numbers 1-9, returns the number spelled out. Otherwise, returns the number. This follows Associated Press style. @@ -31,8 +31,8 @@ You can pass in either an integer or a string representation of an integer. .. templatefilter:: intcomma -intcomma -======== +``intcomma`` +============ Converts an integer to a string containing commas every three digits. @@ -53,8 +53,8 @@ You can pass in either an integer or a string representation of an integer. .. templatefilter:: intword -intword -======= +``intword`` +=========== Converts a large integer to a friendly text representation. Works best for numbers over 1 million. @@ -78,8 +78,8 @@ You can pass in either an integer or a string representation of an integer. .. templatefilter:: naturalday -naturalday -========== +``naturalday`` +============== For dates that are the current day or within one day, return "today", "tomorrow" or "yesterday", as appropriate. Otherwise, format the date using @@ -97,8 +97,8 @@ Examples (when 'today' is 17 Feb 2007): .. templatefilter:: naturaltime -naturaltime -=========== +``naturaltime`` +=============== For datetime values, returns a string representing how many seconds, minutes or hours ago it was -- falling back to the :tfilter:`timesince` @@ -129,8 +129,8 @@ Examples (when 'now' is 17 Feb 2007 16:30:00): .. templatefilter:: ordinal -ordinal -======= +``ordinal`` +=========== Converts an integer to its ordinal as a string. diff --git a/docs/ref/contrib/index.txt b/docs/ref/contrib/index.txt index 8b4b6eaf66..350e665e9d 100644 --- a/docs/ref/contrib/index.txt +++ b/docs/ref/contrib/index.txt @@ -36,8 +36,8 @@ those packages have. staticfiles syndication -admin -===== +``admin`` +========= The automatic Django administrative interface. For more information, see :doc:`Tutorial 2 </intro/tutorial02>` and the @@ -45,23 +45,23 @@ The automatic Django administrative interface. For more information, see Requires the auth_ and contenttypes_ contrib packages to be installed. -auth -==== +``auth`` +======== Django's authentication framework. See :doc:`/topics/auth/index`. -contenttypes -============ +``contenttypes`` +================ A light framework for hooking into "types" of content, where each installed Django model is a separate content type. See the :doc:`contenttypes documentation </ref/contrib/contenttypes>`. -flatpages -========= +``flatpages`` +============= A framework for managing simple "flat" HTML content in a database. @@ -69,52 +69,52 @@ See the :doc:`flatpages documentation </ref/contrib/flatpages>`. Requires the sites_ contrib package to be installed as well. -gis -==== +``gis`` +======= A world-class geospatial framework built on top of Django, that enables storage, manipulation and display of spatial data. See the :doc:`/ref/contrib/gis/index` documentation for more. -humanize -======== +``humanize`` +============ A set of Django template filters useful for adding a "human touch" to data. See the :doc:`humanize documentation </ref/contrib/humanize>`. -messages -======== +``messages`` +============ A framework for storing and retrieving temporary cookie- or session-based messages See the :doc:`messages documentation </ref/contrib/messages>`. -postgres -======== +``postgres`` +============ A collection of PostgreSQL specific features. See the :doc:`contrib.postgres documentation </ref/contrib/postgres/index>`. -redirects -========= +``redirects`` +============= A framework for managing redirects. See the :doc:`redirects documentation </ref/contrib/redirects>`. -sessions -======== +``sessions`` +============ A framework for storing data in anonymous sessions. See the :doc:`sessions documentation </topics/http/sessions>`. -sites -===== +``sites`` +========= A light framework that lets you operate multiple websites off of the same database and Django installation. It gives you hooks for associating objects to @@ -122,15 +122,15 @@ one or more sites. See the :doc:`sites documentation </ref/contrib/sites>`. -sitemaps -======== +``sitemaps`` +============ A framework for generating Google sitemap XML files. See the :doc:`sitemaps documentation </ref/contrib/sitemaps>`. -syndication -=========== +``syndication`` +=============== A framework for generating syndication feeds, in RSS and Atom, quite easily. diff --git a/docs/ref/contrib/postgres/aggregates.txt b/docs/ref/contrib/postgres/aggregates.txt index f9d222c930..aa6d091705 100644 --- a/docs/ref/contrib/postgres/aggregates.txt +++ b/docs/ref/contrib/postgres/aggregates.txt @@ -21,47 +21,47 @@ These functions are described in more detail in the `PostgreSQL docs General-purpose aggregation functions ===================================== -ArrayAgg --------- +``ArrayAgg`` +------------ .. class:: ArrayAgg(expression, **extra) Returns a list of values, including nulls, concatenated into an array. -BitAnd ------- +``BitAnd`` +---------- .. class:: BitAnd(expression, **extra) Returns an ``int`` of the bitwise ``AND`` of all non-null input values, or ``None`` if all values are null. -BitOr ------ +``BitOr`` +--------- .. class:: BitOr(expression, **extra) Returns an ``int`` of the bitwise ``OR`` of all non-null input values, or ``None`` if all values are null. -BoolAnd -------- +``BoolAnd`` +----------- .. class:: BoolAnd(expression, **extra) Returns ``True``, if all input values are true, ``None`` if all values are null or if there are no values, otherwise ``False`` . -BoolOr ------- +``BoolOr`` +---------- .. class:: BoolOr(expression, **extra) Returns ``True`` if at least one input value is true, ``None`` if all values are null or if there are no values, otherwise ``False``. -StringAgg ---------- +``StringAgg`` +------------- .. class:: StringAgg(expression, delimiter) @@ -81,16 +81,16 @@ Aggregate functions for statistics The arguments ``y`` and ``x`` for all these functions can be the name of a field or an expression returning a numeric data. Both are required. -Corr ----- +``Corr`` +-------- .. class:: Corr(y, x) Returns the correlation coefficient as a ``float``, or ``None`` if there aren't any matching rows. -CovarPop --------- +``CovarPop`` +------------ .. class:: CovarPop(y, x, sample=False) @@ -105,32 +105,32 @@ CovarPop However, if ``sample=True``, the return value will be the sample population covariance. -RegrAvgX --------- +``RegrAvgX`` +------------ .. class:: RegrAvgX(y, x) Returns the average of the independent variable (``sum(x)/N``) as a ``float``, or ``None`` if there aren't any matching rows. -RegrAvgY --------- +``RegrAvgY`` +------------ .. class:: RegrAvgY(y, x) Returns the average of the independent variable (``sum(y)/N``) as a ``float``, or ``None`` if there aren't any matching rows. -RegrCount ---------- +``RegrCount`` +------------- .. class:: RegrCount(y, x) Returns an ``int`` of the number of input rows in which both expressions are not null. -RegrIntercept -------------- +``RegrIntercept`` +----------------- .. class:: RegrIntercept(y, x) @@ -138,16 +138,16 @@ RegrIntercept by the ``(x, y)`` pairs as a ``float``, or ``None`` if there aren't any matching rows. -RegrR2 ------- +``RegrR2`` +---------- .. class:: RegrR2(y, x) Returns the square of the correlation coefficient as a ``float``, or ``None`` if there aren't any matching rows. -RegrSlope ---------- +``RegrSlope`` +------------- .. class:: RegrSlope(y, x) @@ -155,16 +155,16 @@ RegrSlope by the ``(x, y)`` pairs as a ``float``, or ``None`` if there aren't any matching rows. -RegrSXX -------- +``RegrSXX`` +----------- .. class:: RegrSXX(y, x) Returns ``sum(x^2) - sum(x)^2/N`` ("sum of squares" of the independent variable) as a ``float``, or ``None`` if there aren't any matching rows. -RegrSXY -------- +``RegrSXY`` +----------- .. class:: RegrSXY(y, x) @@ -172,8 +172,8 @@ RegrSXY times dependent variable) as a ``float``, or ``None`` if there aren't any matching rows. -RegrSYY -------- +``RegrSYY`` +----------- .. class:: RegrSYY(y, x) diff --git a/docs/ref/contrib/postgres/fields.txt b/docs/ref/contrib/postgres/fields.txt index af41666aa7..80b63b9260 100644 --- a/docs/ref/contrib/postgres/fields.txt +++ b/docs/ref/contrib/postgres/fields.txt @@ -7,8 +7,8 @@ module. .. currentmodule:: django.contrib.postgres.fields -ArrayField -========== +``ArrayField`` +============== .. class:: ArrayField(base_field, size=None, **options) @@ -91,8 +91,8 @@ ArrayField If irregular shapes are required, then the underlying field should be made nullable and the values padded with ``None``. -Querying ArrayField -------------------- +Querying ``ArrayField`` +----------------------- There are a number of custom lookups and transforms for :class:`ArrayField`. We will use the following example model:: @@ -109,8 +109,8 @@ We will use the following example model:: .. fieldlookup:: arrayfield.contains -contains -~~~~~~~~ +``contains`` +~~~~~~~~~~~~ The :lookup:`contains` lookup is overridden on :class:`ArrayField`. The returned objects will be those where the values passed are a subset of the @@ -131,8 +131,8 @@ data. It uses the SQL operator ``@>``. For example:: .. fieldlookup:: arrayfield.contained_by -contained_by -~~~~~~~~~~~~ +``contained_by`` +~~~~~~~~~~~~~~~~ This is the inverse of the :lookup:`contains <arrayfield.contains>` lookup - the objects returned will be those where the data is a subset of the values @@ -150,8 +150,8 @@ passed. It uses the SQL operator ``<@``. For example:: .. fieldlookup:: arrayfield.overlap -overlap -~~~~~~~ +``overlap`` +~~~~~~~~~~~ Returns objects where the data shares any results with the values passed. Uses the SQL operator ``&&``. For example:: @@ -168,8 +168,8 @@ the SQL operator ``&&``. For example:: .. fieldlookup:: arrayfield.len -len -~~~ +``len`` +~~~~~~~ Returns the length of the array. The lookups available afterwards are those available for :class:`~django.db.models.IntegerField`. For example:: @@ -242,16 +242,16 @@ lookups available after the transform do not change. For example:: at the database level and cannot be supported in a logical, consistent fashion by Django. -Indexing ArrayField -------------------- +Indexing ``ArrayField`` +----------------------- At present using :attr:`~django.db.models.Field.db_index` will create a ``btree`` index. This does not offer particularly significant help to querying. A more useful index is a ``GIN`` index, which you should create using a :class:`~django.db.migrations.operations.RunSQL` operation. -HStoreField -=========== +``HStoreField`` +=============== .. class:: HStoreField(**options) @@ -292,8 +292,8 @@ HStoreField valid for a given field. This can be done using the :class:`~django.contrib.postgres.validators.KeysValidator`. -Querying HStoreField --------------------- +Querying ``HStoreField`` +------------------------ In addition to the ability to query by key, there are a number of custom lookups available for ``HStoreField``. @@ -340,8 +340,8 @@ need to use the :lookup:`hstorefield.contains` lookup instead. .. fieldlookup:: hstorefield.contains -contains -~~~~~~~~ +``contains`` +~~~~~~~~~~~~ The :lookup:`contains` lookup is overridden on :class:`~django.contrib.postgres.fields.HStoreField`. The returned objects are @@ -360,8 +360,8 @@ field. It uses the SQL operator ``@>``. For example:: .. fieldlookup:: hstorefield.contained_by -contained_by -~~~~~~~~~~~~ +``contained_by`` +~~~~~~~~~~~~~~~~ This is the inverse of the :lookup:`contains <hstorefield.contains>` lookup - the objects returned will be those where the key-value pairs on the object are @@ -380,8 +380,8 @@ example:: .. fieldlookup:: hstorefield.has_key -has_key -~~~~~~~ +``has_key`` +~~~~~~~~~~~ Returns objects where the given key is in the data. Uses the SQL operator ``?``. For example:: @@ -394,8 +394,8 @@ Returns objects where the given key is in the data. Uses the SQL operator .. fieldlookup:: hstorefield.has_any_keys -has_any_keys -~~~~~~~~~~~~ +``has_any_keys`` +~~~~~~~~~~~~~~~~ .. versionadded:: 1.9 @@ -411,8 +411,8 @@ operator ``?|``. For example:: .. fieldlookup:: hstorefield.has_keys -has_keys -~~~~~~~~ +``has_keys`` +~~~~~~~~~~~~ Returns objects where all of the given keys are in the data. Uses the SQL operator ``?&``. For example:: @@ -425,8 +425,8 @@ Returns objects where all of the given keys are in the data. Uses the SQL operat .. fieldlookup:: hstorefield.keys -keys -~~~~ +``keys`` +~~~~~~~~ Returns objects where the array of keys is the given value. Note that the order is not guaranteed to be reliable, so this transform is mainly useful for using @@ -442,8 +442,8 @@ in conjunction with lookups on .. fieldlookup:: hstorefield.values -values -~~~~~~ +``values`` +~~~~~~~~~~ Returns objects where the array of values is the given value. Note that the order is not guaranteed to be reliable, so this transform is mainly useful for @@ -457,8 +457,8 @@ using in conjunction with lookups on >>> Dog.objects.filter(data__values__contains=['collie']) <QuerySet [<Dog: Meg>]> -JSONField -========= +``JSONField`` +============= .. versionadded:: 1.9 @@ -492,8 +492,8 @@ JSONField **As a result, this field requires PostgreSQL ≥ 9.4 and Psycopg2 ≥ 2.5.4**. -Querying JSONField ------------------- +Querying ``JSONField`` +---------------------- We will use the following example model:: @@ -588,8 +588,8 @@ All of the range fields translate to :ref:`psycopg2 Range objects information is necessary. The default is lower bound included, upper bound excluded. -IntegerRangeField ------------------ +``IntegerRangeField`` +--------------------- .. class:: IntegerRangeField(**options) @@ -598,8 +598,8 @@ IntegerRangeField the database and a :class:`~psycopg2:psycopg2.extras.NumericRange` in Python. -BigIntegerRangeField --------------------- +``BigIntegerRangeField`` +------------------------ .. class:: BigIntegerRangeField(**options) @@ -608,8 +608,8 @@ BigIntegerRangeField in the database and a :class:`~psycopg2:psycopg2.extras.NumericRange` in Python. -FloatRangeField ---------------- +``FloatRangeField`` +------------------- .. class:: FloatRangeField(**options) @@ -617,8 +617,8 @@ FloatRangeField :class:`~django.db.models.FloatField`. Represented by a ``numrange`` in the database and a :class:`~psycopg2:psycopg2.extras.NumericRange` in Python. -DateTimeRangeField ------------------- +``DateTimeRangeField`` +---------------------- .. class:: DateTimeRangeField(**options) @@ -627,8 +627,8 @@ DateTimeRangeField the database and a :class:`~psycopg2:psycopg2.extras.DateTimeTZRange` in Python. -DateRangeField --------------- +``DateRangeField`` +------------------ .. class:: DateRangeField(**options) @@ -675,16 +675,16 @@ operators ``@>``, ``<@``, and ``&&`` respectively. .. fieldlookup:: rangefield.contains -contains -^^^^^^^^ +``contains`` +^^^^^^^^^^^^ >>> Event.objects.filter(ages__contains=NumericRange(4, 5)) <QuerySet [<Event: Soft play>]> .. fieldlookup:: rangefield.contained_by -contained_by -^^^^^^^^^^^^ +``contained_by`` +^^^^^^^^^^^^^^^^ >>> Event.objects.filter(ages__contained_by=NumericRange(0, 15)) <QuerySet [<Event: Soft play>]> @@ -707,8 +707,8 @@ contained_by .. fieldlookup:: rangefield.overlap -overlap -^^^^^^^ +``overlap`` +^^^^^^^^^^^ >>> Event.objects.filter(ages__overlap=NumericRange(8, 12)) <QuerySet [<Event: Soft play>]> @@ -724,8 +724,8 @@ the specific range comparison operators. .. fieldlookup:: rangefield.fully_lt -fully_lt -^^^^^^^^ +``fully_lt`` +^^^^^^^^^^^^ The returned ranges are strictly less than the passed range. In other words, all the points in the returned range are less than all those in the passed @@ -736,8 +736,8 @@ range. .. fieldlookup:: rangefield.fully_gt -fully_gt -^^^^^^^^ +``fully_gt`` +^^^^^^^^^^^^ The returned ranges are strictly greater than the passed range. In other words, the all the points in the returned range are greater than all those in the @@ -748,8 +748,8 @@ passed range. .. fieldlookup:: rangefield.not_lt -not_lt -^^^^^^ +``not_lt`` +^^^^^^^^^^ The returned ranges do not contain any points less than the passed range, that is the lower bound of the returned range is at least the lower bound of the @@ -760,8 +760,8 @@ passed range. .. fieldlookup:: rangefield.not_gt -not_gt -^^^^^^ +``not_gt`` +^^^^^^^^^^ The returned ranges do not contain any points greater than the passed range, that is the upper bound of the returned range is at most the upper bound of the @@ -772,8 +772,8 @@ passed range. .. fieldlookup:: rangefield.adjacent_to -adjacent_to -^^^^^^^^^^^ +``adjacent_to`` +^^^^^^^^^^^^^^^ The returned ranges share a bound with the passed range. @@ -788,8 +788,8 @@ lower or upper bound, or query based on emptiness. .. fieldlookup:: rangefield.startswith -startswith -^^^^^^^^^^ +``startswith`` +^^^^^^^^^^^^^^ Returned objects have the given lower bound. Can be chained to valid lookups for the base field. @@ -799,8 +799,8 @@ for the base field. .. fieldlookup:: rangefield.endswith -endswith -^^^^^^^^ +``endswith`` +^^^^^^^^^^^^ Returned objects have the given upper bound. Can be chained to valid lookups for the base field. @@ -810,8 +810,8 @@ for the base field. .. fieldlookup:: rangefield.isempty -isempty -^^^^^^^ +``isempty`` +^^^^^^^^^^^ Returned objects are empty ranges. Can be chained to valid lookups for a :class:`~django.db.models.BooleanField`. diff --git a/docs/ref/contrib/postgres/forms.txt b/docs/ref/contrib/postgres/forms.txt index 288c826f93..c4af819a72 100644 --- a/docs/ref/contrib/postgres/forms.txt +++ b/docs/ref/contrib/postgres/forms.txt @@ -10,8 +10,8 @@ All of these fields and widgets are available from the Fields ====== -SimpleArrayField ----------------- +``SimpleArrayField`` +-------------------- .. class:: SimpleArrayField(base_field, delimiter=',', max_length=None, min_length=None) @@ -82,8 +82,8 @@ SimpleArrayField however it is a useful way to format data from a client-side widget for submission to the server. -SplitArrayField ---------------- +``SplitArrayField`` +------------------- .. class:: SplitArrayField(base_field, size, remove_trailing_nulls=False) @@ -138,8 +138,8 @@ SplitArrayField ['1', '', '3'] # -> [1, None, 3] ['', '2', ''] # -> [None, 2] -HStoreField ------------ +``HStoreField`` +--------------- .. class:: HStoreField @@ -159,8 +159,8 @@ HStoreField valid for a given field. This can be done using the :class:`~django.contrib.postgres.validators.KeysValidator`. -JSONField ---------- +``JSONField`` +------------- .. class:: JSONField @@ -183,8 +183,8 @@ omitted value as an unbounded range. They also validate that the lower bound is not greater than the upper bound. All of these fields use :class:`~django.contrib.postgres.forms.RangeWidget`. -IntegerRangeField -~~~~~~~~~~~~~~~~~ +``IntegerRangeField`` +~~~~~~~~~~~~~~~~~~~~~ .. class:: IntegerRangeField @@ -193,8 +193,8 @@ IntegerRangeField :class:`~django.contrib.postgres.fields.IntegerRangeField` and :class:`~django.contrib.postgres.fields.BigIntegerRangeField`. -FloatRangeField -~~~~~~~~~~~~~~~ +``FloatRangeField`` +~~~~~~~~~~~~~~~~~~~ .. class:: FloatRangeField @@ -202,8 +202,8 @@ FloatRangeField :class:`~psycopg2:psycopg2.extras.NumericRange`. Default for :class:`~django.contrib.postgres.fields.FloatRangeField`. -DateTimeRangeField -~~~~~~~~~~~~~~~~~~ +``DateTimeRangeField`` +~~~~~~~~~~~~~~~~~~~~~~ .. class:: DateTimeRangeField @@ -211,8 +211,8 @@ DateTimeRangeField :class:`~psycopg2:psycopg2.extras.DateTimeTZRange`. Default for :class:`~django.contrib.postgres.fields.DateTimeRangeField`. -DateRangeField -~~~~~~~~~~~~~~ +``DateRangeField`` +~~~~~~~~~~~~~~~~~~ .. class:: DateRangeField @@ -223,8 +223,8 @@ DateRangeField Widgets ======= -RangeWidget ------------ +``RangeWidget`` +--------------- .. class:: RangeWidget(base_widget, attrs=None) diff --git a/docs/ref/contrib/postgres/functions.txt b/docs/ref/contrib/postgres/functions.txt index 25dac99e4d..cc76cdd0e4 100644 --- a/docs/ref/contrib/postgres/functions.txt +++ b/docs/ref/contrib/postgres/functions.txt @@ -7,8 +7,8 @@ All of these functions are available from the .. currentmodule:: django.contrib.postgres.functions -TransactionNow -============== +``TransactionNow`` +================== .. class:: TransactionNow() diff --git a/docs/ref/contrib/postgres/lookups.txt b/docs/ref/contrib/postgres/lookups.txt index 83477a61fe..1f0af07b0d 100644 --- a/docs/ref/contrib/postgres/lookups.txt +++ b/docs/ref/contrib/postgres/lookups.txt @@ -2,8 +2,8 @@ PostgreSQL specific lookups =========================== -Unaccent -======== +``Unaccent`` +============ .. fieldlookup:: unaccent diff --git a/docs/ref/contrib/postgres/operations.txt b/docs/ref/contrib/postgres/operations.txt index 81ecb6acb2..b889105283 100644 --- a/docs/ref/contrib/postgres/operations.txt +++ b/docs/ref/contrib/postgres/operations.txt @@ -7,8 +7,8 @@ the ``django.contrib.postgres.operations`` module. .. currentmodule:: django.contrib.postgres.operations -CreateExtension -=============== +``CreateExtension`` +=================== .. class:: CreateExtension(name) @@ -18,8 +18,8 @@ CreateExtension This is a required argument. The name of the extension to be installed. -HStoreExtension -=============== +``HStoreExtension`` +=================== .. class:: HStoreExtension() @@ -27,8 +27,8 @@ HStoreExtension which will install the ``hstore`` extension and also immediately set up the connection to interpret hstore data. -UnaccentExtension -================= +``UnaccentExtension`` +===================== .. class:: UnaccentExtension() diff --git a/docs/ref/contrib/postgres/validators.txt b/docs/ref/contrib/postgres/validators.txt index 21a1935f55..ad29cb7f0d 100644 --- a/docs/ref/contrib/postgres/validators.txt +++ b/docs/ref/contrib/postgres/validators.txt @@ -22,11 +22,17 @@ Validators Range validators ================ +``RangeMaxValueValidator`` +-------------------------- + .. class:: RangeMaxValueValidator(limit_value, message=None) Validates that the upper bound of the range is not greater than ``limit_value``. +``RangeMinValueValidator`` +-------------------------- + .. class:: RangeMinValueValidator(limit_value, message=None) Validates that the lower bound of the range is not less than the diff --git a/docs/ref/contrib/sitemaps.txt b/docs/ref/contrib/sitemaps.txt index 58c5e71a31..42e2543e4d 100644 --- a/docs/ref/contrib/sitemaps.txt +++ b/docs/ref/contrib/sitemaps.txt @@ -75,8 +75,8 @@ The sitemap view takes an extra, required argument: ``{'sitemaps': sitemaps}``. a :class:`~django.contrib.sitemaps.Sitemap` class (e.g., ``BlogSitemap(some_var)``). -Sitemap classes -=============== +``Sitemap`` classes +=================== A :class:`~django.contrib.sitemaps.Sitemap` class is a simple Python class that represents a "section" of entries in your sitemap. For example, @@ -129,8 +129,8 @@ Note: :attr:`~Sitemap.location()` calls ``get_absolute_url()`` on each object and returns the result. -Sitemap class reference -======================= +``Sitemap`` class reference +=========================== .. class:: Sitemap diff --git a/docs/ref/contrib/staticfiles.txt b/docs/ref/contrib/staticfiles.txt index b6da4b98d2..e09bdaad49 100644 --- a/docs/ref/contrib/staticfiles.txt +++ b/docs/ref/contrib/staticfiles.txt @@ -1,6 +1,6 @@ -=================== -The staticfiles app -=================== +======================= +The ``staticfiles`` app +======================= .. module:: django.contrib.staticfiles :synopsis: An app for handling static files. @@ -34,8 +34,8 @@ Management Commands ``django.contrib.staticfiles`` exposes three management commands. -collectstatic -------------- +``collectstatic`` +----------------- .. django-admin:: collectstatic @@ -128,8 +128,8 @@ For a full list of options, refer to the commands own help by running:: $ python manage.py collectstatic --help -findstatic ----------- +``findstatic`` +-------------- .. django-admin:: findstatic static file [static file ...] @@ -177,8 +177,8 @@ the directories which were searched:: .. _staticfiles-runserver: -runserver ---------- +``runserver`` +------------- .. django-admin:: runserver [addrport] @@ -218,8 +218,8 @@ Example usage:: Storages ======== -StaticFilesStorage ------------------- +``StaticFilesStorage`` +---------------------- .. class:: storage.StaticFilesStorage @@ -238,8 +238,8 @@ The :class:`~django.contrib.staticfiles.storage.CachedStaticFilesStorage` uses this behind the scenes to replace the paths with their hashed counterparts and update the cache appropriately. -ManifestStaticFilesStorage --------------------------- +``ManifestStaticFilesStorage`` +------------------------------ .. class:: storage.ManifestStaticFilesStorage @@ -317,8 +317,8 @@ hashing algorithm. .. _`url()`: http://www.w3.org/TR/CSS2/syndata.html#uri .. _`Cascading Style Sheets`: http://www.w3.org/Style/CSS/ -CachedStaticFilesStorage ------------------------- +``CachedStaticFilesStorage`` +---------------------------- .. class:: storage.CachedStaticFilesStorage diff --git a/docs/ref/contrib/syndication.txt b/docs/ref/contrib/syndication.txt index 080b0a526c..5146c98fed 100644 --- a/docs/ref/contrib/syndication.txt +++ b/docs/ref/contrib/syndication.txt @@ -31,8 +31,8 @@ feed, write a :class:`~django.contrib.syndication.views.Feed` class and point to an instance of it in your :doc:`URLconf </topics/http/urls>`. -Feed classes ------------- +``Feed`` classes +---------------- A :class:`~django.contrib.syndication.views.Feed` class is a Python class that represents a syndication feed. A feed can be simple (e.g., @@ -381,8 +381,8 @@ And the accompanying URLconf:: # ... ] -Feed class reference --------------------- +``Feed`` class reference +------------------------ .. class:: views.Feed |
