Path: csiph.com!feeder.erje.net!1.eu.feeder.erje.net!ecngs!feeder2.ecngs.de!87.79.20.101.MISMATCH!newsreader4.netcologne.de!news.netcologne.de!peer03.ams1!peer.ams1.xlned.com!news.xlned.com!peer03.fr7!futter-mich.highwinds-media.com!news.highwinds-media.com!fx34.am4.POSTED!not-for-mail Received-SPF: unknown (Address does not pass the Sender Policy Framework) SPF=MAILFROM; sender=macek@sandbox.cz; remoteip=::ffff:87.236.197.188; remotehost=; helo=mx.sandbox.cz; receiver=hugo.zagamma.cz; From: =?UTF-8?B?VmzDocSPYSBNYWNlaw==?= User-Agent: Mozilla/5.0 (X11; Linux i686; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Received-SPF: unknown (Address does not pass the Sender Policy Framework) SPF=FROM; sender=macek@sandbox.cz; remoteip=::ffff:87.236.197.188; remotehost=; helo=mx.sandbox.cz; receiver=hugo.zagamma.cz; Subject: Re: [python] =?utf-8?q?alternativa_textwrap=2Efill=28=29=2C_kter?= =?utf-8?b?w6EgYnkgemFyb3Zuw6F2YWxhIHBvIMSNZXNrdT8=?= X-BeenThere: python@py.cz X-Mailman-Version: 2.1.23 Precedence: list List-Id: Konference PyCZ List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: cz.comp.lang.python Message-ID: X-Mailman-Original-Message-ID: <17124f05-2e0e-bddf-6b84-81efa2df2616@sandbox.cz> X-Mailman-Original-References: References: <17124f05-2e0e-bddf-6b84-81efa2df2616@sandbox.cz> Lines: 29 X-Complaints-To: abuse@usenet-news.net NNTP-Posting-Date: Wed, 10 May 2017 22:28:10 UTC Organization: usenet-news.net Date: Thu, 11 May 2017 00:28:09 +0200 X-Received-Bytes: 3155 X-Received-Body-CRC: 4500831 Xref: csiph.com cz.comp.lang.python:3175 On 10.5.2017 23:51, Matěj Cepl wrote: > On 2017-05-10, 21:02 GMT, Honza Král wrote: >> spravne by melo byt nahradit mezeru na predlozkami >> nezlomitelnymi mezerami >> (https://cs.wikipedia.org/wiki/Nezlomitelná_mezera) a tim >> padem by vse pak melo fungovat jak ma. > O nezlomitelných mezerách samozřejmě vím (vlna je můj oblíbený > program), ale bohužel textwrap.fill na to nereaguje. > > https://mcepl.fedorapeople.org/tmp/kobylky.py > > Matěj > Pitomy... :-) Chapu. Asi bych se zkusil nenamahat a vzal bych si vetsi kladivo. :-) print textwrap.fill(instr, width=65).replace(u'~', unichr(160)) Vim, ze je to prdly, ale dokud existuje bug https://bugs.python.org/issue20491, jde to snesitelny workaround, rekl bych. Neznam aplikaci, ale je to cele fakt potreba? Pokud nekdo cte text wrapovany na terminal, obvykle prezije nevhodne zalomeni jednopismennych slov... Nerejpu. V.