[wingide-users] Formatting of documentation in source assistant

Wingware Support support at wingware.com
Mon May 7 09:48:49 MDT 2007


Markus Meyer wrote:
> Wingware Support schrieb:
>> If you right click on the source assistant you can turn off wrapping
>> of lines.  The wrapping is being done by the widget, which of course
>> has no idea what it's doing and doesn't support a wrap-to-indent
>> mode.  We should probably just not indent docstrings to avoid this
>> issue.
> Thanks for the tip! Unfortunately, this will hide part of the text which
> is even worse. What about providing two modes:
> 
> * Do not wrap lines: Displays docstrings as-is, but without the fixed
> indent for the whole docstring (makes more room for the actual text
> 
> * Wrap lines: Ignores all indents and new lines and displays doc strings
> as paragraphs of text which are separated by a blank line (i.e. the way
> HTML and Latex treat text).

I've just implemented basically this for Wing 3.0, with some attempted
smartness about indented things which usually shouldn't be wrapped.  I'm
sure it'll need some refinement...

> Additionally, there could be some form of "smart detection" of paragraph
> type. E.g., paragraphs which are evidently pre-formatted (have
> table-like layout like lists of parameters or paragraphs with keywords
> like "@param") would not be auto-wrapped.

Yes, there's more we can do here.  I expect both for the general case
and for doctests and similar.

-- 

Stephan Deibel
Wingware | Python IDE
Advancing Software Development

www.wingware.com



More information about the wingide-users mailing list