http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=2499
--- Comment #4 from Chris Nighswonger <[email protected]> --- I'm not sure what approach you've taken, but here is the problem code: http://git.koha-community.org/gitweb/?p=koha.git;a=blob;f=C4/Labels/Label.pm;h=760bacfed998674f9b6544bae7a25b0f9d4aa811;hb=HEAD#l433 433 eval{$Text::Wrap::columns = $self->{'text_wrap_cols'};}; 434 my @line = split(/\n/ ,wrap('', '', $field_data)); 435 # If this is a title field, limit to two lines; all others limit to one... FIXME: this is rather arbitrary 436 if ($field->{'code'} eq 'title' && scalar(@line) >= 2) { 437 while (scalar(@line) > 2) { 438 pop @line; 439 } 440 } else { 441 while (scalar(@line) > 1) { 442 pop @line; 443 } 444 } 445 push(@label_lines, @line); 446 } As it is it is, well, rather arbitrary. A little while later we do something much more intelligent to figure line width in the justification routine: 450 my $string_width = C4::Creators::PDF->StrWidth($line, $font, $self->{'font_size'}); Something similar could be done to replace the arbitrary method back at lines 433-446. -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
