View on
MetaCPAN
Barry King > Apache-Wyrd > Apache::Wyrd::Interfaces::Columnize

Download:
Apache-Wyrd-0.98.tar.gz

Dependencies

Annotate this POD

View/Report Bugs
Module Version: 0.98   Source  

NAME ^

Apache::Wyrd::Interfaces::Columnize - Add limited table auto-formatting

SYNOPSIS ^

        use base qw(Apache::Wyrd::Intefaces::Columnize Apache::Wyrd);

        sub _format_output {
                my ($self) = @_;
                my @items = $self->_get_items;
                my $data = $self->_columnize(@items);
                $self->_data($data);
        }

DESCRIPTION ^

Arranges a given array of items into a table based on the number found in the Wyrd's columns attribute.

Currently, the interface also will interpret the style attribute of the Wyrd to be included as the named style of the table data (TD) tags it uses to build the table. It also looks to the cellpadding and cellspacing attributes to pass to the enclosing table. These criteria are under review may change in the future.

HTML ATTRIBUTES ^

columns

The number of columns the table will consist of. The table will be line- broken based on this number of columns.

direction

When set to "down", will arrange the items left-column first, moving right. Otherwise, they are arranged left to right across the columns.

METHOD ^

_columnize

Takes an array of items, assumed to be HTML text and arranges them in columns (by default, across-first) of an HTML Table, and returns the text of that table.

AUTHOR ^

Barry King <wyrd@nospam.wyrdwright.com>

SEE ALSO ^

Apache::Wyrd

General-purpose HTML-embeddable perl object

LICENSE ^

Copyright 2002-2007 Wyrdwright, Inc. and licensed under the GNU GPL.

See LICENSE under the documentation for Apache::Wyrd.

syntax highlighting: