12 my $tree = HTML::TreeBuilder->new->parse_file($fn);
13 my ($chapter) = $tree->look_down( "_tag", "div", "class", "chapter", );
14 return '' unless ($chapter);
15 my $formatter = HTML::FormatText->new( leftmargin => 0, rightmargin => 72 );
17 my $text = $formatter->format($chapter);
23 foreach my $fn ( glob("$dir/ch*.html") ) {
27 print process_chapter($fn);