-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
More documentation #114
Closed
Closed
More documentation #114
Changes from 40 commits
Commits
Show all changes
46 commits
Select commit
Hold shift + click to select a range
b76a435
Fixes #2, Gfb.rename().
4f3d02d
Merge branch 'master' of github.com:UV-CDAT/vcs
f3611de
Working on vcs documentation again.
7e88272
Trying to fix doctest strings
52ace16
Trying to get testing to work
0aba23b
Fixing errors for tests
629005c
Working on a script to parse doctest output for error warnings
0145d63
Running individual modules through doctest and processing output
d6fc033
Working on doctest_vcs.py
d69364a
Working on doctest scripts
09ad094
Working on improving doctest reporting
357f78f
Added README.md with links to doctest logs
b145bc6
Fixed README to be markdown friendly
f5941bb
Fixed errors in manageElements. Added doctests. General formatting im…
3013bf8
Merge branch 'master' of github.com:UV-CDAT/vcs into more_documentation
6605397
Adding doctests where they are missing.
58e2bf2
Adding doctests/documentation where necessary.
56b73a6
Fixing/adding doctests
4d4a002
Added more examples/doctests to utils.py .
d384ae5
Tweaked doctest cleanup. Fixed manageElements doctests.
9f797d4
Organized doctest_info directory.
b46416d
Fixed reference to old branch in README.md
2c74fc1
Docstring formatting. Doctest corrections. Changed Not Yet Implemente…
1d4e7b4
doctest_vcs.py now filters out private functions from the missing
c965894
Fixed more docstring formatting issues.
7447eda
Fixing up template. Deleted old file in scripts/
532a2be
Undocumented some internal functions to template.
bbe545f
Updating logs.
87ffae3
Fixed taylordiagram examples
37d2a40
Added example to mtics doc
51cea2a
Adding doctests to xmldocs:
bab6725
Fixed doctests for ticlabels, exts
711abb6
Refactored doctest_vcs.py and re-ran tests.
14bed4e
Working on extracting repetetive params to xmldocs.
4d9efc3
Re-factored xmldocs formatting.
5b159e5
Added functionality to ignore certain regular expressions when
570ffe8
Added an Index of VCS functions for the pdf output.
eb08920
Added README.md to doctest_info directories briefly explaining
8bbbeef
Formatted :Example: sections to <=80 lines so they look better
b8897f1
Removed Makefile call to old function
11b67d9
Adds doctest_info/ to .gitignore.
6c75ccd
Added '.. pragma: skip-doctest' statements in some places they are
3b2635b
Added lots of '.. pragma: skip-doctest' and fixed some broken tests.
d9b1313
Added skip-doctest to some docstrings.
ee36e7b
Standardized print statements for .list()
572fba4
Added things to stop tests from breaking
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
File renamed without changes.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
import vcs, inspect | ||
|
||
# VCS objects to generate function references for. Some are modules, some are classes. | ||
# Probably will need to add to this later when there's more documentation | ||
objects = [ | ||
vcs.boxfill.Gfb, | ||
vcs.Canvas.Canvas, | ||
vcs.colormap.Cp, | ||
vcs.fillarea.Tf, | ||
vcs.isofill.Gfi, | ||
vcs.isoline.Gi, | ||
vcs.line.Tl, | ||
vcs.marker.Tm, | ||
vcs.meshfill.Gfm, | ||
vcs.projection.Proj, | ||
vcs.taylor.Gtd, | ||
vcs.template.P, | ||
vcs.textcombined.Tc, | ||
vcs.textorientation.To, | ||
vcs.texttable.Tt, | ||
vcs.unified1D.G1d, | ||
vcs.vector.Gv, | ||
vcs.manageElements, | ||
vcs.queries, | ||
vcs.utils | ||
] | ||
|
||
# iterate through objects to find the functions of each, and write RST links for those out to | ||
# API/functions/$MODULE_NAME.rst | ||
for obj in objects: | ||
if inspect.isclass(obj): | ||
key = obj.__module__ + '.' + obj.__name__ | ||
pred = inspect.ismethod | ||
else: | ||
key = obj.__name__ | ||
pred = inspect.isfunction | ||
funcs = [] | ||
tup_l = inspect.getmembers(obj, predicate=pred) | ||
for tup in tup_l: | ||
if not tup[0][0] == '_': | ||
funcs.append(':func:`' + key + '.' + tup[0] + '`\n\n') | ||
fname = key.split('.')[1] | ||
with open('functions/' + fname + ".rst", "w+") as f: | ||
f.write(fname + "\n") | ||
map(lambda x: f.write('-'), range(len(fname))) | ||
f.write("\n\n") | ||
f.writelines(funcs) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,307 @@ | ||
Canvas | ||
------ | ||
|
||
:func:`vcs.Canvas.Canvas.addfont` | ||
|
||
:func:`vcs.Canvas.Canvas.boxfill` | ||
|
||
:func:`vcs.Canvas.Canvas.canvasid` | ||
|
||
:func:`vcs.Canvas.Canvas.canvasinfo` | ||
|
||
:func:`vcs.Canvas.Canvas.cgm` | ||
|
||
:func:`vcs.Canvas.Canvas.change_display_graphic_method` | ||
|
||
:func:`vcs.Canvas.Canvas.check_name_source` | ||
|
||
:func:`vcs.Canvas.Canvas.clean_auto_generated_objects` | ||
|
||
:func:`vcs.Canvas.Canvas.clear` | ||
|
||
:func:`vcs.Canvas.Canvas.close` | ||
|
||
:func:`vcs.Canvas.Canvas.configure` | ||
|
||
:func:`vcs.Canvas.Canvas.copyfontto` | ||
|
||
:func:`vcs.Canvas.Canvas.create1d` | ||
|
||
:func:`vcs.Canvas.Canvas.create3d_dual_scalar` | ||
|
||
:func:`vcs.Canvas.Canvas.create3d_scalar` | ||
|
||
:func:`vcs.Canvas.Canvas.create3d_vector` | ||
|
||
:func:`vcs.Canvas.Canvas.createboxfill` | ||
|
||
:func:`vcs.Canvas.Canvas.createcolormap` | ||
|
||
:func:`vcs.Canvas.Canvas.createfillarea` | ||
|
||
:func:`vcs.Canvas.Canvas.createisofill` | ||
|
||
:func:`vcs.Canvas.Canvas.createisoline` | ||
|
||
:func:`vcs.Canvas.Canvas.createline` | ||
|
||
:func:`vcs.Canvas.Canvas.createmarker` | ||
|
||
:func:`vcs.Canvas.Canvas.createmeshfill` | ||
|
||
:func:`vcs.Canvas.Canvas.createprojection` | ||
|
||
:func:`vcs.Canvas.Canvas.createscatter` | ||
|
||
:func:`vcs.Canvas.Canvas.createtaylordiagram` | ||
|
||
:func:`vcs.Canvas.Canvas.createtemplate` | ||
|
||
:func:`vcs.Canvas.Canvas.createtext` | ||
|
||
:func:`vcs.Canvas.Canvas.createtextcombined` | ||
|
||
:func:`vcs.Canvas.Canvas.createtextorientation` | ||
|
||
:func:`vcs.Canvas.Canvas.createtexttable` | ||
|
||
:func:`vcs.Canvas.Canvas.createvector` | ||
|
||
:func:`vcs.Canvas.Canvas.createxvsy` | ||
|
||
:func:`vcs.Canvas.Canvas.createxyvsy` | ||
|
||
:func:`vcs.Canvas.Canvas.createyxvsx` | ||
|
||
:func:`vcs.Canvas.Canvas.destroy` | ||
|
||
:func:`vcs.Canvas.Canvas.drawfillarea` | ||
|
||
:func:`vcs.Canvas.Canvas.drawline` | ||
|
||
:func:`vcs.Canvas.Canvas.drawlogooff` | ||
|
||
:func:`vcs.Canvas.Canvas.drawlogoon` | ||
|
||
:func:`vcs.Canvas.Canvas.drawmarker` | ||
|
||
:func:`vcs.Canvas.Canvas.drawtext` | ||
|
||
:func:`vcs.Canvas.Canvas.drawtextcombined` | ||
|
||
:func:`vcs.Canvas.Canvas.dual_scalar3d` | ||
|
||
:func:`vcs.Canvas.Canvas.dummy_user_action` | ||
|
||
:func:`vcs.Canvas.Canvas.endconfigure` | ||
|
||
:func:`vcs.Canvas.Canvas.eps` | ||
|
||
:func:`vcs.Canvas.Canvas.ffmpeg` | ||
|
||
:func:`vcs.Canvas.Canvas.fillarea` | ||
|
||
:func:`vcs.Canvas.Canvas.flush` | ||
|
||
:func:`vcs.Canvas.Canvas.geometry` | ||
|
||
:func:`vcs.Canvas.Canvas.get1d` | ||
|
||
:func:`vcs.Canvas.Canvas.get3d_dual_scalar` | ||
|
||
:func:`vcs.Canvas.Canvas.get3d_scalar` | ||
|
||
:func:`vcs.Canvas.Canvas.get3d_vector` | ||
|
||
:func:`vcs.Canvas.Canvas.get_selected_display` | ||
|
||
:func:`vcs.Canvas.Canvas.getantialiasing` | ||
|
||
:func:`vcs.Canvas.Canvas.getboxfill` | ||
|
||
:func:`vcs.Canvas.Canvas.getcolorcell` | ||
|
||
:func:`vcs.Canvas.Canvas.getcolormap` | ||
|
||
:func:`vcs.Canvas.Canvas.getcolormapname` | ||
|
||
:func:`vcs.Canvas.Canvas.getcontinentsline` | ||
|
||
:func:`vcs.Canvas.Canvas.getcontinentstype` | ||
|
||
:func:`vcs.Canvas.Canvas.getdrawlogo` | ||
|
||
:func:`vcs.Canvas.Canvas.getfillarea` | ||
|
||
:func:`vcs.Canvas.Canvas.getfont` | ||
|
||
:func:`vcs.Canvas.Canvas.getfontname` | ||
|
||
:func:`vcs.Canvas.Canvas.getfontnumber` | ||
|
||
:func:`vcs.Canvas.Canvas.getisofill` | ||
|
||
:func:`vcs.Canvas.Canvas.getisoline` | ||
|
||
:func:`vcs.Canvas.Canvas.getline` | ||
|
||
:func:`vcs.Canvas.Canvas.getmarker` | ||
|
||
:func:`vcs.Canvas.Canvas.getmeshfill` | ||
|
||
:func:`vcs.Canvas.Canvas.getplot` | ||
|
||
:func:`vcs.Canvas.Canvas.getprojection` | ||
|
||
:func:`vcs.Canvas.Canvas.getscatter` | ||
|
||
:func:`vcs.Canvas.Canvas.gettaylordiagram` | ||
|
||
:func:`vcs.Canvas.Canvas.gettemplate` | ||
|
||
:func:`vcs.Canvas.Canvas.gettext` | ||
|
||
:func:`vcs.Canvas.Canvas.gettextcombined` | ||
|
||
:func:`vcs.Canvas.Canvas.gettextextent` | ||
|
||
:func:`vcs.Canvas.Canvas.gettextorientation` | ||
|
||
:func:`vcs.Canvas.Canvas.gettexttable` | ||
|
||
:func:`vcs.Canvas.Canvas.getvector` | ||
|
||
:func:`vcs.Canvas.Canvas.getxvsy` | ||
|
||
:func:`vcs.Canvas.Canvas.getxyvsy` | ||
|
||
:func:`vcs.Canvas.Canvas.getyxvsx` | ||
|
||
:func:`vcs.Canvas.Canvas.gif` | ||
|
||
:func:`vcs.Canvas.Canvas.grid` | ||
|
||
:func:`vcs.Canvas.Canvas.gs` | ||
|
||
:func:`vcs.Canvas.Canvas.initLogoDrawing` | ||
|
||
:func:`vcs.Canvas.Canvas.interact` | ||
|
||
:func:`vcs.Canvas.Canvas.isinfile` | ||
|
||
:func:`vcs.Canvas.Canvas.islandscape` | ||
|
||
:func:`vcs.Canvas.Canvas.isofill` | ||
|
||
:func:`vcs.Canvas.Canvas.isoline` | ||
|
||
:func:`vcs.Canvas.Canvas.isopened` | ||
|
||
:func:`vcs.Canvas.Canvas.isportrait` | ||
|
||
:func:`vcs.Canvas.Canvas.landscape` | ||
|
||
:func:`vcs.Canvas.Canvas.line` | ||
|
||
:func:`vcs.Canvas.Canvas.listelements` | ||
|
||
:func:`vcs.Canvas.Canvas.marker` | ||
|
||
:func:`vcs.Canvas.Canvas.match_color` | ||
|
||
:func:`vcs.Canvas.Canvas.meshfill` | ||
|
||
:func:`vcs.Canvas.Canvas.objecthelp` | ||
|
||
:func:`vcs.Canvas.Canvas.onClosing` | ||
|
||
:func:`vcs.Canvas.Canvas.open` | ||
|
||
:func:`vcs.Canvas.Canvas.orientation` | ||
|
||
:func:`vcs.Canvas.Canvas.pdf` | ||
|
||
:func:`vcs.Canvas.Canvas.plot` | ||
|
||
:func:`vcs.Canvas.Canvas.plot_annotation` | ||
|
||
:func:`vcs.Canvas.Canvas.plot_filledcontinents` | ||
|
||
:func:`vcs.Canvas.Canvas.png` | ||
|
||
:func:`vcs.Canvas.Canvas.portrait` | ||
|
||
:func:`vcs.Canvas.Canvas.postscript` | ||
|
||
:func:`vcs.Canvas.Canvas.processParameterChange` | ||
|
||
:func:`vcs.Canvas.Canvas.pstogif` | ||
|
||
:func:`vcs.Canvas.Canvas.put_png_on_canvas` | ||
|
||
:func:`vcs.Canvas.Canvas.raisecanvas` | ||
|
||
:func:`vcs.Canvas.Canvas.removeP` | ||
|
||
:func:`vcs.Canvas.Canvas.remove_display_name` | ||
|
||
:func:`vcs.Canvas.Canvas.removeobject` | ||
|
||
:func:`vcs.Canvas.Canvas.return_display_names` | ||
|
||
:func:`vcs.Canvas.Canvas.savecontinentstype` | ||
|
||
:func:`vcs.Canvas.Canvas.saveinitialfile` | ||
|
||
:func:`vcs.Canvas.Canvas.scalar3d` | ||
|
||
:func:`vcs.Canvas.Canvas.scatter` | ||
|
||
:func:`vcs.Canvas.Canvas.scriptobject` | ||
|
||
:func:`vcs.Canvas.Canvas.scriptrun` | ||
|
||
:func:`vcs.Canvas.Canvas.setAnimationStepper` | ||
|
||
:func:`vcs.Canvas.Canvas.setantialiasing` | ||
|
||
:func:`vcs.Canvas.Canvas.setbgoutputdimensions` | ||
|
||
:func:`vcs.Canvas.Canvas.setcolorcell` | ||
|
||
:func:`vcs.Canvas.Canvas.setcolormap` | ||
|
||
:func:`vcs.Canvas.Canvas.setcontinentsline` | ||
|
||
:func:`vcs.Canvas.Canvas.setcontinentstype` | ||
|
||
:func:`vcs.Canvas.Canvas.setdefaultfont` | ||
|
||
:func:`vcs.Canvas.Canvas.show` | ||
|
||
:func:`vcs.Canvas.Canvas.start` | ||
|
||
:func:`vcs.Canvas.Canvas.svg` | ||
|
||
:func:`vcs.Canvas.Canvas.switchfonts` | ||
|
||
:func:`vcs.Canvas.Canvas.taylordiagram` | ||
|
||
:func:`vcs.Canvas.Canvas.text` | ||
|
||
:func:`vcs.Canvas.Canvas.textcombined` | ||
|
||
:func:`vcs.Canvas.Canvas.update` | ||
|
||
:func:`vcs.Canvas.Canvas.updateorientation` | ||
|
||
:func:`vcs.Canvas.Canvas.vector` | ||
|
||
:func:`vcs.Canvas.Canvas.vector3d` | ||
|
||
:func:`vcs.Canvas.Canvas.xvsy` | ||
|
||
:func:`vcs.Canvas.Canvas.xyvsy` | ||
|
||
:func:`vcs.Canvas.Canvas.yxvsx` | ||
|
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
boxfill | ||
------- | ||
|
||
:func:`vcs.boxfill.Gfb.colors` | ||
|
||
:func:`vcs.boxfill.Gfb.datawc` | ||
|
||
:func:`vcs.boxfill.Gfb.exts` | ||
|
||
:func:`vcs.boxfill.Gfb.getlegendlabels` | ||
|
||
:func:`vcs.boxfill.Gfb.getlevels` | ||
|
||
:func:`vcs.boxfill.Gfb.list` | ||
|
||
:func:`vcs.boxfill.Gfb.rename` | ||
|
||
:func:`vcs.boxfill.Gfb.script` | ||
|
||
:func:`vcs.boxfill.Gfb.xmtics` | ||
|
||
:func:`vcs.boxfill.Gfb.xticlabels` | ||
|
||
:func:`vcs.boxfill.Gfb.xyscale` | ||
|
||
:func:`vcs.boxfill.Gfb.ymtics` | ||
|
||
:func:`vcs.boxfill.Gfb.yticlabels` | ||
|
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@embrown is htis automatically generated or did you have to manually create this one?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@aashish24 I have a script in docs/API that builds this out. It checks all of VCS's modules using the
inspect
library, and prints out an RST-formatted link to the appropriate file (https://github.com/embrown/vcs/blob/more_more_documentation/docs/API/build_func_index.py).