diff options
author | root <root@frank.tg14.gathering.org> | 2014-04-16 15:55:09 +0200 |
---|---|---|
committer | root <root@frank.tg14.gathering.org> | 2014-04-16 15:55:09 +0200 |
commit | 3430d3f965ddac5d24890d56462049b4402084cd (patch) | |
tree | 5307ae2d8aa209361b5ef87a8d958f519de0e952 | |
parent | 35a1d8178ec6e1af28864a6ebd75cb2cc68f7490 (diff) |
Tweak the shortening in nettkart.
-rwxr-xr-x | web/nms.gathering.org/nettkart.pl | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/web/nms.gathering.org/nettkart.pl b/web/nms.gathering.org/nettkart.pl index 6711dae..f6dd2c2 100755 --- a/web/nms.gathering.org/nettkart.pl +++ b/web/nms.gathering.org/nettkart.pl @@ -99,7 +99,7 @@ while (my $ref = $q->fetchrow_hashref()) { my $max_textlen = ($x2-$x1) > ($y2-$y1) ? $x2-$x1 : $y2-$y1; while (length($sysname) * 6 > $max_textlen) { # Try to abbreviate sysname if it is too long for the box - $sysname =~ s/^(.*)[a-z]~?([0-9]+)$/$1~$2/ or last; + $sysname =~ s/^(.*)[a-z]~?([0-9-]+)$/$1~$2/ or last; } if (($x2-$x1) > ($y2-$y1)) { $text_img->string(gdSmallFont,$x1+2,$y1,$sysname,$blk); |