in reply to Re: General Purpose String Padding
in thread General Purpose String Padding

Perl6::Form does not seem to be a solution to a simpler form of this.

I would still need to create the template by using something like:

my $template = $dir eq 'R' ? '<' x $max_length : '>' x $max_length;
Also, I do not see anything about padding with a specific character. It seems Perl6::Form only pads with spaces.
See this portion now, thanks Grandfather.

Still quite a nice module though, I will have to remember it for general formatting in the future.

Replies are listed 'Best First'.
Re^3: General Purpose String Padding
by ikegami (Patriarch) on Feb 01, 2006 at 21:19 UTC
    The idea would be to discard $max_length entirely. Whatever is providing the value stored in $max_length would now provide a form/template. Of course, this is not necessarily possible in your case.