Subject: ANNOUNCE: Text::Flowchart 1.00
From: [email-masked] (Jim Thomason)
Date: 24 Dec 1999 17:50:12 GMT
Newsgroups: comp.lang.perl.announce,comp.lang.perl.modules

This will look best in a mono-spaced font.  Sorry to all those using
newsreaders with variable width-fonts, but I just couldn't help myself.

+-------+      +-------------------------+
| BEGIN >--+   |                         |
+-------+  +---> I would like to         |
               | announce a new module:  |
               | Text::Flowchart         |
               |                         |
               +---V---------------------+
                   |
               +---V-----------+        +--------------------+
               |               |        |                    |
    +----------Y Do you care?  |        | Go play Pac-Man,   >----+
    |          |               N-+      | or something       |    |
    |          +---------------+ |      |                    |    |
    |                            |      +---^-^--------------+    |
    |                            |          | |                   |
+---V---------+          +-------V-----+    | |                   |
|             |          |             |    | +---+               |
| Oh good.    |          | Phooey.     >----+     |               |
|             |          | Fine.  I    |       +--^----------+    |
+-V-----------+      +---> don't like  |       |             |    |
  |                  |   | you anyway. |       | So go try   |    |
  +----+             |   |             |    +--> that.       |    |
   +---V---------+   |   +------^------+    |  |             |    |
   |             |   |          |           |  +-------------+    |
   | Is an ASCII N---+      +---+           |                     |
   | flowchart   |     +----N--------+   +--^-------------------+ |
   | fine with   |     |             |   |                      | |
   | you?        Y--+  | Would you   Y--->Then I would recommend| |
   |             |  |  | like some   |   |Text::Flowchart.      | |
   +-------------+  +--> help?       |   |                      | |
                       |             |   +----------------------+ |
                       +-------------+        +-------------------V--+
                                              | And yes, this        |
                                              | flowchart was        |
                                      +-------< generated with the   |
                          +----+      |       | module               |
                          | :) <------+       +----------------------+
                          +----+

In short, Text::Flowchart is a new object-oriented module designed to
make your lives easier, assuming of course that your lives involve
making ASCII flowcharts.

I created the above flowchart in about 10 minutes.  It certainly can't
compete with a fancy-schmancy presentation program designed for this
sort of thing, but as long as you're not making a presentation to the
vice president of marketing, this should definitely make your lives easier.

Here's a code sample:

use Text::Flowchart;

$flowchart = Text::Flowchart->new(
   "width" => 50,
   "directed" => 1);
 
$begin = $flowchart->box(
   "string" => "BEGIN",
   "x_coord" => 0,
   "y_coord" => 0,
   "width" => 9,
   "y_pad" => 0
);

$end = $flowchart->box(
   "string" => "END",
   "x_coord" => 10,
   "y_coord" => 5,
   "width" => 7,
   "y_pad" => 0
);

$flowchart->relate( [$begin, "right"] => [$end, "top", 2] );

$flowchart->draw();

---
Which outputs:

+-------+
| BEGIN >----+
+-------+    |
             |
             |
          +--V--+
          | END |
          +-----+
          
Enjoy.

-Jim Thomason
[email-masked]