Req #14694 [Fbk->NoF]: GNU fmt-like linebreak algorithm as PHP function
| From: | php-bugs at lists dot php dot net | Date: | Tue, 30 Dec 2014 10:41:02 +0000 |
| Subject: | Req #14694 [Fbk->NoF]: GNU fmt-like linebreak algorithm as PHP function | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-189346@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=14694&edit=1
ID: 14694
Updated by: php-bugs@lists.php.net
Reported by: d-r at roettsches dot de
Summary: GNU fmt-like linebreak algorithm as PHP function
-Status: Feedback
+Status: No Feedback
Type: Feature/Change Request
Package: *General Issues
Operating System: All
PHP Version: *
Private report: N
New Comment:
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
Previous Comments:
------------------------------------------------------------------------
[2014-04-16 16:35:39] levim@php.net
Are you still interested in seeing this? As far as I know this still hasn't been implemented.
------------------------------------------------------------------------
[2001-12-25 18:16:03] d-r at roettsches dot de
Hi there,
I've been searching for a PHP implementation of the GNU textformatting tool fmt
(http://www.gnu.org/software/textutils/textutils.html) which provides an almost optimal linebreak
for your text.
It would be better to use than wordwrap() because it avoids breaking sentences after the first word
or leaving dangling ends (paragraphs with only one word on the last line). The algorithm used by fmt
is similar to the one used by Tex/Latex (proposed by a paper of Knuth et al.) and thus stands for
optimal output quality.
My question is, if there's anyone who is interested in implementing this for PHP, so that we
can see it in one of the next releases?
I think, the function would be very useful to do some pretty reformatting of text when for example
sending mail or in general doing text formatted output.
Thanks for your help in advance,
Dominik
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=14694&edit=1