gtaylor / python-colormath

A python module that abstracts common color math operations. For example, converting from CIE L*a*b to XYZ, or from RGB to CMYK
python-colormath.readthedocs.org
BSD 3-Clause "New" or "Revised" License
456 stars 83 forks source link

Docstrings for color objects #8

Closed endolith closed 11 years ago

endolith commented 11 years ago

What do you think of making docstrings for all the objects like this in numpy format?

gtaylor commented 11 years ago

Thanks for taking the time to do this, but if there were any format I'd want to institute, it'd be Sphinx-style ReST. I use it for all of my other projects, and really like how it reads.

endolith commented 11 years ago

Isn't that the same thing? https://github.com/numpy/numpy/blob/master/doc/HOWTO_DOCUMENT.rst.txt

Anyway these should have some type of docstrings describing the parameters

gtaylor commented 11 years ago

Kind of. You've got the params done differently. Check out the Python domain in Sphinx.

For example:

"""
Short docstring

:param str somearg: Blah blah blah
:keyword str optional: Yay
:returns: blah
:rtype: str
"""