pretty: fix printing of long strings e.g. pi.evalf(100)   (#941)
pretty: fix printing of long strings e.g. pi.evalf(100)   (#941)

When pretty needs to print long stringPicts, we see at what terminal width is,
and wraps the picture. Also currently we add vertical spacer between blocks.

For mathematical formulas with height > 1 this is certainly the right thing to
do, e.g.:

       2  2        3        3    4    4
    6*x *y  + 4*x*y  + 4*y*x  + x  + y

is wrapped into this:

       2  2        3
    6*x *y  + 4*x*y  +
                        <-- note vertical spacer
         3    4    4
    4*y*x  + x  + y


But if we'll look at pi.evalf(100), or long dict or another string which is
originally 1-character in height, it seems putting such v-spacers is not
convenient:


In [2]: pi.evalf(48)    |  In [2]: pi.evalf(48)
Out[2]:                 |  Out[2]:
3.14159265358979323     |  3.14159265358979323
8462643383279502884     |
19716939937             |  8462643383279502884
                        |
                        |  19716939937


That's why I propose we stop adding this v-spacers if original picture is
1-character in height.



Signed-off-by: Kirill Smelkov <b0eeaac46e675e9f95bf68c0df1041cf581c26f4@landau.phys.spbu.ru>
Signed-off-by: Ondrej Certik <b816faa87b7d35274d2e545c5be11ed4376f3ccf@certik.cz>

jaimahajan1997/sympy,ga7g08/sympy,emon10005/sympy,abloomston/sympy,farhaanbukhsh/sympy,hazelnusse/sympy-old,AunShiLord/sympy,wanglongqi/sympy,jerli/sympy,kaichogami/sympy,drufat/sympy,sunny94/temp,mafiya69/sympy,Curious72/sympy,garvitr/sympy,jamesblunt/sympy,jerli/sympy,kumarkrishna/sympy,amitjamadagni/sympy,debugger22/sympy,hazelnusse/sympy-old,rahuldan/sympy,sampadsaha5/sympy,ga7g08/sympy,liangjiaxing/sympy,mafiya69/sympy,Arafatk/sympy,aktech/sympy,tovrstra/sympy,pandeyadarsh/sympy,emon10005/sympy,lindsayad/sympy,sampadsaha5/sympy,VaibhavAgarwalVA/sympy,jbaayen/sympy,meghana1995/sympy,beni55/sympy,toolforger/sympy,MechCoder/sympy,iamutkarshtiwari/sympy,MechCoder/sympy,cccfran/sympy,abhiii5459/sympy,kevalds51/sympy,jamesblunt/sympy,amitjamadagni/sympy,abloomston/sympy,postvakje/sympy,kaushik94/sympy,yashsharan/sympy,Curious72/sympy,shipci/sympy,Mitchkoens/sympy,Gadal/sympy,ChristinaZografou/sympy,shipci/sympy,lindsayad/sympy,hargup/sympy,minrk/sympy,mafiya69/sympy,yukoba/sympy,postvakje/sympy,pandeyadarsh/sympy,bukzor/sympy,KevinGoodsell/sympy,kmacinnis/sympy,asm666/sympy,MridulS/sympy,grevutiu-gabriel/sympy,AkademieOlympia/sympy,hargup/sympy,wyom/sympy,hrashk/sympy,liangjiaxing/sympy,Shaswat27/sympy,madan96/sympy,yukoba/sympy,Vishluck/sympy,dqnykamp/sympy,skirpichev/omg,Titan-C/sympy,chaffra/sympy,AkademieOlympia/sympy,Arafatk/sympy,wanglongqi/sympy,flacjacket/sympy,jaimahajan1997/sympy,jbbskinny/sympy,vipulroxx/sympy,souravsingh/sympy,sunny94/temp,lidavidm/sympy,bukzor/sympy,sahilshekhawat/sympy,maniteja123/sympy,MechCoder/sympy,oliverlee/sympy,AunShiLord/sympy,Gadal/sympy,beni55/sympy,drufat/sympy,pandeyadarsh/sympy,toolforger/sympy,oliverlee/sympy,chaffra/sympy,jamesblunt/sympy,ahhda/sympy,kumarkrishna/sympy,Gadal/sympy,liangjiaxing/sympy,souravsingh/sympy,iamutkarshtiwari/sympy,vipulroxx/sympy,sahmed95/sympy,grevutiu-gabriel/sympy,Curious72/sympy,aktech/sympy,madan96/sympy,Shaswat27/sympy,asm666/sympy,atreyv/sympy,AunShiLord/sympy,moble/sympy,postvakje/sympy,ga7g08/sympy,sahmed95/sympy,shipci/sympy,drufat/sympy,maniteja123/sympy,kaushik94/sympy,MridulS/sympy,abhiii5459/sympy,sampadsaha5/sympy,Sumith1896/sympy,madan96/sympy,saurabhjn76/sympy,cswiercz/sympy,yashsharan/sympy,ChristinaZografou/sympy,shikil/sympy,srjoglekar246/sympy,rahuldan/sympy,jbbskinny/sympy,Designist/sympy,mattpap/sympy-polys,meghana1995/sympy,emon10005/sympy,atsao72/sympy,moble/sympy,Designist/sympy,pbrady/sympy,dqnykamp/sympy,beni55/sympy,Titan-C/sympy,rahuldan/sympy,aktech/sympy,kevalds51/sympy,debugger22/sympy,abhiii5459/sympy,hargup/sympy,jbbskinny/sympy,Arafatk/sympy,cccfran/sympy,Vishluck/sympy,skidzo/sympy,garvitr/sympy,ChristinaZografou/sympy,atsao72/sympy,Davidjohnwilson/sympy,garvitr/sympy,bukzor/sympy,farhaanbukhsh/sympy,atsao72/sympy,lidavidm/sympy,ahhda/sympy,VaibhavAgarwalVA/sympy,atreyv/sympy,Davidjohnwilson/sympy,lidavidm/sympy,farhaanbukhsh/sympy,cswiercz/sympy,shikil/sympy,skidzo/sympy,chaffra/sympy,minrk/sympy,Mitchkoens/sympy,grevutiu-gabriel/sympy,vipulroxx/sympy,ahhda/sympy,Vishluck/sympy,MridulS/sympy,VaibhavAgarwalVA/sympy,lindsayad/sympy,saurabhjn76/sympy,pernici/sympy,oliverlee/sympy,hrashk/sympy,fperez/sympy,yashsharan/sympy,mcdaniel67/sympy,kmacinnis/sympy,souravsingh/sympy,cccfran/sympy,mcdaniel67/sympy,Mitchkoens/sympy,abloomston/sympy,sunny94/temp,ryanGT/sympy,kevalds51/sympy,Designist/sympy,kaichogami/sympy,iamutkarshtiwari/sympy,dqnykamp/sympy,maniteja123/sympy,yukoba/sympy,jaimahajan1997/sympy,AkademieOlympia/sympy,kaushik94/sympy,Shaswat27/sympy,shikil/sympy,wanglongqi/sympy,kumarkrishna/sympy,cswiercz/sympy,jerli/sympy,pbrady/sympy,Davidjohnwilson/sympy,meghana1995/sympy,skidzo/sympy,wyom/sympy,sahmed95/sympy,saurabhjn76/sympy,Sumith1896/sympy,Sumith1896/sympy,kmacinnis/sympy,atreyv/sympy,moble/sympy,wyom/sympy,mcdaniel67/sympy,pbrady/sympy,asm666/sympy,sahilshekhawat/sympy,sahilshekhawat/sympy,toolforger/sympy,diofant/diofant,debugger22/sympy,kaichogami/sympy,Titan-C/sympy,hrashk/sympy