in reply to Re^2: Headings in Perl6::Form
in thread Headings in Perl6::Form

It's probably a bug (and certainly not desirable). I've reported it. The only workaround I can find at the moment is to use "\xa0" (a single non-breaking space) where no data is available. Like so:
#! /usr/bin/perl -w use strict; use 5.010; use Perl6::Form; my @last = qw(Smith Jones Wright Wong Evans McFee Ho Nuygen Willians H +owlett Jones Peters Milford Tam Lam Soma Egon Wilson); my @first = qw(Jim Jack Wendy Lee Bo Lenord Jan Dana Lindy Kyle Nora J +ane Bill Woo John Mick Lazlo Jenna); my @mid = ("\xa0", "\xa0", 'A', "\xa0", "B", "\xa0", "\xa0", 'A', "\ +xa0", "B", "\xa0", "\xa0", 'A', "\xa0", "B", "\xa0", "\xa0", 'A'); my @suf = ("") x 18; my @nick = qw(Jim Jack Wendy Lee Bo Lenord Jan Dana Lindy Kyle Nora Ja +ne Bill Woo John Mick Lazlo Jenna); my @ID = 1..18; print form { page => { length => 15, number => 1, feed => "\f", footer => "________________________________ +_____________________________________\n", header => { first => "================================ +=====================================\n" . "| xxxxxxxxxxxx +xxxxxxxxxxxxxxxx |\n" . "| xxxxxxxxxx +xxxxxxxxxxxx |\n" . "| + |\n" . "| List +of Players |\n" . "|=============================== +====================================|\n" . "|Last |First + |MI|Suffix|Nickname | ID|\n" . "|_______________________________ +____________________________________|", other => "================================ +=====================================\n" . "| List +of Players |\n" . "|=============================== +====================================|\n" . "|Last |First + |MI|Suffix|Nickname | ID|\n" . "|------------------------------- +------------------------------------|", } } }, "| {]]]]]]]]]]]]]]]]} | {]]]]]]]]]]]]]]]]} |{}| {II} | {]]]]]]} | +{} |\n", \@last, \@first, \@mid,\@suf, \@nick, \ +@ID;

Replies are listed 'Best First'.
Re^4: Headings in Perl6::Form
by BigJerry (Initiate) on Aug 28, 2011 at 23:36 UTC

    Thanks again! This works, but each field replaced with the non-breaking space prints as a "?' which is not visually appealing. I did, however, find a slightly different solution which works for me.

    Following the documentation, I was trying to append a "\r" to each field to get a blank line after each row. Using a single "\r" didn't give me the blank line, but I noticed that it did get rid of the '?' in the blank columns. I discovered that if I appended "\r\r" I both got rid of the '?' in the blank columns and I got my blank line after each row. I'm a happy camper!