in reply to Auto text format cleanup via Win32::Clipboard

++ man....but how about s/\t/ /g or something to filter out tabs?

______________________________________________
RIP
Douglas Noel Adams
1952 - 2001

Replies are listed 'Best First'.
Re: Re: Auto text format cleanup via Win32::Clipboard
by gryphon (Abbot) on Aug 20, 2001 at 02:58 UTC

    Greetings EvanK,

    Actually on line 16 (if you include spaces) the line that reads:

    $text =~ s/[ \n\t\f]+/ /g;

    will sub-out all tabs and other stuff for spaces. I would have put \s except I used \r as a paragraph delimiter, so I had to specifically specify the \s set without \r in it.

    -gryphon
    code('Perl') || die;

    Update: Oops. Sorry, just noticed you were replying to "version 1" not the updated code. You're right, I should have added that...