Skip Menu |

This queue is for tickets about the Unicode-LineBreak CPAN distribution.

Report information
The Basics
Id: 125896
Status: new
Priority: 0/
Queue: Unicode-LineBreak

Owner: Nobody in particular
Requestors: dmuey [...]

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)

Subject: Math based on columns() seems correct but actual columns in use (using a monospace font) can be wrong
Download (untitled) / with headers
text/plain 662b
If you run the attached script in a terminal that does utf8 correctly and has a good Monospaced Unicode font like Menlo you'll note that the 🤔line is too far right. It is as if it actually takes up 2 columns but it is reported as 1 column. May not matter but it is a 5 digit code point and the others are 4. Thanks! ``` | I am ascii.......... | | ‼ what!............. | | ⁇ curious........... | | ✏️ take note......... | | 🤔 hmmm.............. | $VAR1 = { "\x{1f914} hmmm" => 6, "\x{203c} what!" => 7, 'I am ascii' => 10, "\x{2047} curious" => 9, "\x{270f}\x{fe0f} take note" => 11 }; ```
text/x-perl 448b
use strict; use warnings; use Data::Dumper; use Unicode::GCString; binmode STDOUT, ":utf8"; my %strings; my @strings = ( "I am ascii", "‼ what!", "⁇ curious", "✏️ take note", "🤔 hmmm" ); for my $str (@strings) { utf8::decode($str); my $cols = Unicode::GCString->new($str)->columns; $strings{$str} = $cols; my $pad = "." x ( 20 - $cols ); print "| $str$pad |\n"; } print Dumper( \%strings );
Download (untitled) / with headers
text/plain 101b
Note: In the terminal the ✏️line is aligned ok (on rt it looks like the 🤔does on the terminal)

This service is sponsored and maintained by Best Practical Solutions and runs on infrastructure.

Please report any issues with to