# strips the __doc__ strings from BlenderPython # Based on original version for older version of blender by: # c.wartmann@gmx.net # Thanks to Zr for the eval tip # Rewritten 14Dec2002 by # AndrewSenior http://www.andrewsenior.com/home.html import Blender import sys # import string #print Blender.Types.__dict__ from types import TupleType, FloatType, ListType, TypeType, FunctionType, IntType, ModuleType, BuiltinFunctionType, NoneType, StringType, BufferType, SliceType, FrameType, InstanceType, DictType def printmod(module): if (module.__name__[0]=="_"): return print "
" print "Module: ", module.__name__,"

" for item in dir(module): itemob= eval(module.__name__ + "." + item) itemtype= type(itemob) if (itemtype==ModuleType): printmod(itemob) elif (item=="__builtins__"): print "Builtins: __builtins__
" elif (itemtype==DictType): print "Dict: ", item, "", itemob,"
" elif (itemtype==IntType): print "Int: ", item, "", itemob,"
" elif (itemtype==FloatType): print "Float: ", item, "", itemob,"
" elif (itemtype==ListType): print "List: ", item, "", itemob,"
" elif (itemtype==TupleType): print "Tuple: ", item, "", itemob,"
" elif (itemtype==StringType): if (item !="__name__" and item !="__doc__"): print "String: ", item, " \""+itemob+"\"
" elif (itemtype==TypeType): print "Type: ", item, "", itemob,"
" elif (itemtype==Blender.Types.BufferType): print "BlBuffer: ", item, "", itemob,"
" elif (itemtype==Blender.Types.ButtonType): print "BlButton: ", item, "", itemob,"
" elif (itemtype==Blender.Types.VectorType): print "BlVector: ", item, "", itemob,"
" elif (itemtype==Blender.Types.MatrixType): print "BlMatrix: ", item, "", itemob,"
" elif (itemtype==Blender.Types.BlockType): print "BlBlock: ", item, "", itemob,"
" elif (itemtype==FunctionType): print "Function: ", item, "", itemob,"
" elif (itemtype==BuiltinFunctionType): print "BuiltinFunction: ", item, "", itemob,"
" elif (itemtype==NoneType): print "None: ", item,"
" elif (itemtype==InstanceType): print "Instance: ", item, "", itemob,"
" elif (itemtype==FrameType): print "Frame: ", item, "", itemob,"
" elif (itemtype==SliceType): print "Slice: ", item, "", itemob,"
" else: print "Unknown: ", item, "", itemob,"
" print "End of Module: ", module.__name__,"


" # Outfile dat=open("/home/aws/blender/pydoc.html","w") std=sys.stdout sys.stdout=dat # HTML Header print "BlenderPython __doc__ Strings" printmod(Blender.Types) printmod(Blender) print "
" print "All information copyright 2002 by Stichting Blender Foundation" print "www.blender.org" print "" sys.stdout=std dat.close()