PY-30103 Add wrapping for long function signatures

Similarly to how it's done for Java and other languages parameters are
wrapped and aligned always if there are more than one of them. Also, the
need to wrap the return type annotation is detected naively by checking
whether the length of the last line containing it exceeds 80 characters.
This commit is contained in:
Mikhail Golubev
2018-06-03 00:48:14 +03:00
parent 5988a48236
commit 9e118e01a9
22 changed files with 125 additions and 34 deletions

View File

@@ -1 +1 @@
<html><body><div class='definition'><pre>Property <b>m</b> of <a href="psi_element://#typename#PropNewDocstringOfGetter.C">PropNewDocstringOfGetter.C</a><br>@<i>m.setter</i><br>def&nbsp;<b>m</b>(self:&nbsp;<a href="psi_element://#typename#C">C</a>,&nbsp;x:&nbsp;Any)&nbsp;-&gt;&nbsp;None</pre></div><div class='content'>Foo</div><table class='sections'><tr><td valign='top' class='section'><p>Documentation is copied from:</td><td valign='top'>property getter</td><tr><td valign='top' class='section'><p>Accessor kind:</td><td valign='top'>Setter</td></table></body></html>
<html><body><div class='definition'><pre>Property <b>m</b> of <a href="psi_element://#typename#PropNewDocstringOfGetter.C">PropNewDocstringOfGetter.C</a><br>@<i>m.setter</i><br>def&nbsp;<b>m</b>(self:&nbsp;<a href="psi_element://#typename#C">C</a>,<br> x:&nbsp;Any)&nbsp;-&gt;&nbsp;None</pre></div><div class='content'>Foo</div><table class='sections'><tr><td valign='top' class='section'><p>Documentation is copied from:</td><td valign='top'>property getter</td><tr><td valign='top' class='section'><p>Accessor kind:</td><td valign='top'>Setter</td></table></body></html>