#NEWLINE# def docstring_headline( obj ) : #NEWLINE# #INDENT# if ( not obj . __doc__ ) : #NEWLINE# #INDENT# return '' #NEWLINE# #UNINDENT# res = [ ] #NEWLINE# for line in obj . __doc__ . strip ( ) . splitlines ( ) : #NEWLINE# #INDENT# if line . strip ( ) : #NEWLINE# #INDENT# res . append ( ( ' ' + line . strip ( ) ) ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# break #NEWLINE# #UNINDENT# #UNINDENT# return '' . join ( res ) . lstrip ( )