Is the change in the word wrap rule possible?

Jean-Marc Desperrier jmdesp at
Fri Nov 9 17:56:43 UTC 2007

Marc Schumann wrote:
> 2007/11/6, Komiyama Yukie <ykomi5 at>:
>> Users of my Bugzilla are using English and Japanese.
>> X : Character of Japanese
>> --- Present result ----
>> XXXXXXissue 
>> statusXXXXXXXXX[omission]XXXXXX
>> --- Wanted result ----
>> XXXXXXissue statusXXXXXXXXX[omission]XX
>> In version 3.0(utf-8), is the change in the word wrap rule possible?
> [...]
>> Could you teach the method of changing the rule of word wrap?
>> I have not edited *.pm file.
>> And, I was not able to find the wrap() function* where being described.
> you probably need to look at function wrap_comment in Bugzilla/

According to Yukie's description, it seems like this wrap_comment 
function has a serious i18n problem .

When I look in lxr, everything's done using Text::Wrap :

And when I look at Text::Wrap in CPAN, it looks like it might known 
nothing about i18n :
"It is possible to control which characters terminate words by modifying 
$Text::Wrap::break. [...] The default is simply '\s'; that is, words are 
terminated by spaces."

I think the solution is to replace it with Unicode::Wrap :
This module implements UAX#14: Line Breaking Properties.

Unfortunately, Unicode::Wrap doesn't seem to be a direct replacement, 
also it might have performance problems "This module can be slow. It's a 
pure-Perl implementation that goes through an expensive classification 
process per character."
And it won't do Thai correctly ;-)

dev-apps-bugzilla mailing list
dev-apps-bugzilla at

More information about the developers mailing list