in reply to Re: Text::Autoformat not behaving correctly
in thread Text::Autoformat not behaving correctly

Thanks. Apparently the lack of a definition of what constitutes a paragraph to Text::Autoformat has gotten to me. You would think that according to the module's documentation that it would be able to discern what a paragraph is and what isn't. Its not really clear in the paragraph section.

Quote:
The fundamental task of the autoformat subroutine is to identify and rearrange independent paragraphs in a text. Paragraphs typically consist of a series of lines containing at least one non-whitespace character, followed by one or more lines containing only optional whitespace. This is a more liberal definition than many other formatters use: most require an empty line to terminate a paragraph. Paragraphs may also be denoted by bulleting, numbering, or quoting (see the following sections).

Once a paragraph has been isolated, autoformat fills and re-wraps its lines according to the margins that are specified in its argument list. These are placed after the text to be formatted, in a hash reference:


++ to you BikeNomad

BMaximus
  • Comment on Re: Re: Text::Autoformat not behaving correctly

Replies are listed 'Best First'.
Re: Re: Re: Text::Autoformat not behaving correctly
by frag (Hermit) on Jun 22, 2001 at 09:37 UTC
    If you can get a copy of the latest Perl Journal (#20), Damian Conway's written an article about Text::Autoformat that discusses this. Quote: "autoformat understands all these notions of a paragraph. Even when they're all used at once. Even when they're used inside one another (for example, quoting a list of bulleted points)."

    -- Frag.