Generating python docs with EPYDOC

Compiling, libraries, modules, coding guidelines and porting

Moderators: jesterKing, stiv

Post Reply
ideasman
Posts: 0
Joined: Tue Feb 25, 2003 2:37 pm

Generating python docs with EPYDOC

Post by ideasman » Mon Apr 05, 2004 11:37 am

Mabe this is a python question.

When I get the cvs and compile it Id also like to compile the python docs,
I discovered that the docs on blenders website are generated with the epydoc package.

I got the package but because of the way blender is not a py or so file, I need to accsess the Blender module- within Blender it would seem.

Anybody know how>?

-Cam

Michel
Posts: 180
Joined: Wed Oct 16, 2002 7:27 pm
Location: Somewhere below the rivers in Holland (but not Limburg)

Re: Generating python docs with EPYDOC

Post by Michel » Mon Apr 05, 2004 1:02 pm

Hi,

go to the source/blender/python/api2_2x/doc directory. There you'll find the epydoc.sh script. This script let's you quickly generate new Python documentation.

With regards,
Michel
You can have one of two things: Progress or Progress Reports.

snifi
Posts: 0
Joined: Sun Feb 25, 2007 5:39 pm

Post by snifi » Mon Mar 31, 2008 12:55 pm

Hello there, this is an old thread, but I think my question goes right here:

Are these Python files in folder

/blender-2.45/source/blender/python/api2_2x/doc

made automaticly from the C-source someway, or is this the place where you collect the documentation? When I write in Interactive Console the commands e.g. dir(Scene) or help(Scene), from where exactly do these commands take the information?

I'm writing an Python script, that wants to show an info-window of a given function, module or object, (I'd like the output to be about the same as in Blender Python Api html-pages) should I make an own routine to collect an database and index, like Epydoc does, and from where?

I hope you understand my question.

stiv
Posts: 0
Joined: Tue Aug 05, 2003 7:58 am
Location: 45N 86W

Post by stiv » Mon Mar 31, 2008 6:07 pm

The files in the .../api2_2x/doc dir are used to generate the html docs. They are essentially python class definitions with some special epydoc markup.

The docs strings for the classes and methods are embedded in the C source files. This is what you see when you print some_method_or_class.__doc__ .

NielsBlender

Post by NielsBlender » Mon Mar 31, 2008 9:16 pm

ideasman,

After the epydoc-install:

epydoc.py -o "c:\blender\bpy_doc" --name "Blender" --url "http:\\www.blender.org" --top API_intro --no-private sourcecode:yes imports:yes inheritance:listed introspect:yes parse:yes docformat:epytext simple-term:0 debug:0 verbosity:0 output:html modules: "C:\blender\blender\source\blender\python\api2_2x\doc\*"

Of course c:\blender\etc is my path, and make sure you have the .py extension pick-up by python.

Hope this helps,
Niels

stiv
Posts: 0
Joined: Tue Aug 05, 2003 7:58 am
Location: 45N 86W

Post by stiv » Mon Mar 31, 2008 11:22 pm

Jeez, Niels. Try not to respond to posts that are more than 3 years old. And for the record, the included script for generating the docs is called epy_docgen.sh.

NielsBlender

Post by NielsBlender » Wed Apr 02, 2008 9:50 pm

stiv wrote:Jeez, Niels. Try not to respond to posts that are more than 3 years old. And for the record, the included script for generating the docs is called epy_docgen.sh.
stiv, I already had noticed, I saw no reason to add anything, since people might still find it useful these days...

And for the record: ".sh" a *nix-shell extension doesn't work at all on Windows... (but I noticed the file at the time already yes...)

Hope this helps,
Niels

ps.
Yes, I also know way(s) to run a .sh-file on Windows...


ps2.
Just tried if python swallows the .sh file.... yes, unfortunatly both give errors... and don't generate anything...

Post Reply