Data::Reporter::RepFormat

RepFormat is a Perl module that allows text formatting with simple instructions, mapping to a user-defined grid (the sheet).
Download

Data::Reporter::RepFormat Ranking & Summary

Advertisement

  • Rating:
  • License:
  • Perl Artistic License
  • Price:
  • FREE
  • Publisher Name:
  • Ricardo Vazquez
  • Publisher web site:
  • http://search.cpan.org/~rvaz/Data-Reporter-1.4/Reporter/RepFormat.pm http://search.cpan.org/~rvaz/Data-Reporter-1.4/Reporter/RepFormat.pm

Data::Reporter::RepFormat Tags


Data::Reporter::RepFormat Description

RepFormat is a Perl module that allows text formatting with simple instructions, mapping to a user-defined grid (the sheet). SYNOPSIS use Data::Reporter::RepFormat; $sheet = new Data::Reporter::RepFormat($cols, $rows); $sheet->Move(0,3); $sheet->Print('123'); $sheet->Out(); $sheet->Clear(); $sheet->Printf('0d', 12); $sheet->MVPrint(0, 3, '123'); $sheet->MVPrintf(0, 1, '%3.2f', 79.123); $sheet->Nlines(); $sheet->Getline(20); $sheet->Copy($source_sheet); $sheet->Center('hello', 10); my $pic = $sheet->ToPicture('$$$,999, 999', 1234.56); $value = $sheet->Commify('1234567.89');new($cols, $rows)Creates a new RepFormat object. This function receives two parameters: columms and rows of the sheet.$sheet->Move($col, $row)Moves cursor to the indicated position$sheet->Print($string)Puts $string at the current cursor position.$sheet->Out()Moves the sheet information to target output. If $handle is not specified, then STDOUT is used.$sheet->Clear()Clears the sheet$sheet->Printf(format, argument)Prints using printf style format$sheet->MVPrint($col, $row, $string)Moves, then Prints$sheet->MVPrintf($col, $row, format, argument)Moves, then Prints (using printf style format)$sheet->Nlines()Returns the number of lines in the sheet, discarding the last blank lines$sheet->getX()Returns current column position (X)$sheet->getY()Returns current row position (Y)$sheet->Getline($index)Returns the $index row$sheet->Copy($source_sheet)Appends $source_sheet in $sheet$sheet->Center($string, $size)Returns a string with size = $size having $string centered in it. This function uses spaces to pad on both sides.$sheet->Commify($number);Returns $number as a string with commas (123456789.90 -> 123,456,789.90)*NOTE This function will be no longer supported in next releases. Use PrintP instead.$sheet->printP($string, $picture);Puts a string at the current position with $string in the specified $picture. Requirements: · Perl


Data::Reporter::RepFormat Related Software