Skip to content

Commit 6083ec2

Browse files
author
Tony S Yu
committed
call attention to note about coordinate systems and add stylesheet to highlight attention directive
1 parent 1ee2451 commit 6083ec2

3 files changed

Lines changed: 20 additions & 6 deletions

File tree

doc/source/_static/quantities.css

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
@import "sphinxdoc.css";
2+
3+
div.attention p.admonition-title {
4+
color: black;
5+
background-color: #FFF305;
6+
}

doc/source/conf.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,7 @@
9191
# must exist either in Sphinx' static/ path, or in one of the custom paths
9292
# given in html_static_path.
9393
html_theme = 'sphinxdoc'
94+
html_style = 'quantities.css'
9495

9596
# Theme options are theme-specific and customize the look and feel of a theme
9697
# further. For a list of options available for each theme, see the

quantities/__init__.py

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -221,12 +221,19 @@
221221
When unicode is enabled, strings used to designate units should still
222222
conform to valid python expressions.
223223
224-
One final note: Quantities is not a package for describing coordinate
225-
systems that require a point of reference, like positions on a map or
226-
absolute temperature scales. Proper support of coordinate systems
227-
would be a fairly large undertaking and is outside the scope of this
228-
project.
229-
224+
.. attention::
225+
Quantities is not a package for describing coordinate systems that require a
226+
point of reference, like positions on a map. In particular, Quantities does
227+
not support absolute temperature scales. Instead, temperatures are assumed to
228+
be temperature *differences*. For example:
229+
230+
>>> T = 20 * pq.degC
231+
>>> print T.rescale('K')
232+
20.0 K
233+
234+
Proper support of coordinate systems would be a fairly large undertaking and
235+
is outside the scope of this project.
236+
230237
"""
231238

232239
#from __future__ import absolute_import

0 commit comments

Comments
 (0)