Hi,

I don't speak format, perlform is short on examples

so I haven't figured out the answer to your question but I kinda like this

#!/usr/bin/perl -- use strict; use warnings; Main( @ARGV ); exit( 0 ); { use constant +{ qw{ TYPE 0 NAME 1 ACTION 2 } }; ## to undefine globals TYPE/NAME/ACTION outside of this block use namespace::clean; format OFG = @<<<<<<<< @<<<<<<<<<<<<<<<<<<<< @<<<<<< $_[TYPE], $_[NAME], $_[ACTION] . } format THREECHARFORMAT = ^<<~~ $_[0] . sub fwThree { return formatWrite( *STDOUT, "::THREECHARFORMAT", @_ ); } sub formatWrite { use IO::Handle; my $handle = shift; my $format = shift; local @_ = @_; $handle->format_name( $format ); write $handle; } sub Main { fwThree("foobar"); formatWrite( *STDOUT, "::OFG", qw/ TYPE NAME ACTION / ); formatWrite( *STDERR, "::OFG", TYPE(), NAME(), ACTION() ); } __END__ $ perl format.fill.overflow.11113982.pl foo bar TYPE NAME ACTION Undefined subroutine &main::TYPE called at format.fill.overflow.111139 +82.pl line 56.

I would abandon format, switch to Perl6::Form, cause format appears to be one ignored wart (see Perl format line breaking, $FORMAT_LINE_BREAK_CHARACTERS apparently ignored )

Perl6::Form comes with demos, not sure if one fits what you want
https://metacpan.org/source/DCONWAY/Perl6-Form-0.090/demo/demo_break_word.pl
https://metacpan.org/source/DCONWAY/Perl6-Form-0.090/demo/demo_break_width.pl
https://metacpan.org/source/DCONWAY/Perl6-Form-0.090/demo/demo_overflowed_columns.pl


In reply to Re: disabling forced line break with format fill mode and long source word (perlform Perl6::Form) by Anonymous Monk
in thread disabling forced line break with format fill mode and long source word by karlberry

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.