The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Mail::Thread::Arc - Generates a Thread Arc reperesentation of a thread

SYNOPSIS

 my $threader = Mail::Thread->new( @messages );
 my $arc = Mail::Thread::Arc->new;

 $threader->thread;

 my $i;
 for my $thread ($threader->rootset) {
     ++$i;
     my $svg = $arc->render( $thread );
     write_file( "thread_$i.svg", $svg->xmlify );
 }

DESCRIPTION

Mail::Thread::Arc takes a Mail::Thread::Container and generates an image of the Thread Arc. Thread Arcs are described in the documentation for IBM's remail project.

http://www.research.ibm.com/remail/

METHODS

new

Generic constructor, inherited from Class::Accessor::Chained::Fast

render( $root_container, %options )

The main method.

Renders the thread tree as a thread arc. Returns an SVG object.

draw_message( $message )

Draw the message on the SVG canvas.

make_link( $message )

Return an URI based on the message. By default returns undef meaning that that the message is not a link.

However if this module is subclassed then a meaningful URI can be returned where appropriate.

draw_arc( $from, $to )

draws an arc between two messages

message_radius

The radius of the message circles. The most magic of all the magic numbers.

message_style( $container )

Returns the style hash for the message circle.

maximum_arc_height

the maximum height of an arc. default is 17 message radii

arc_style( $from, $to )

Returns the style hash for the connecting arc,

message_x( $container )

returns the X co-ordinate for a message

message_y

returns the Y co-ordinate for a message (expected to be constant for all messages)

thread_generation( $message )

returns the thread generation of the container.

date_of( $container )

The date the message was sent, in epoch seconds

AUTHOR

Richard Clamp <richardc@unixbeard.net>

COPYRIGHT

Copyright (C) 2003 Richard Clamp. All Rights Reserved.

This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

SEE ALSO

ReMail, the IBM Research project that implements Thread Arcs.

http://unixbeard.net/~richardc/mta/ - some sample output, alongside .pngs created with batik-rasteriser.

Mail::Thread, Mail::Thread::Chronological, SVG