In our previous episode (Friday, 01-Mar-2013), Maarten Sneep said:
> Does the Hard Wrap command work in this way? As far as I can tell it acts on
> the whole document if nothing is selected, and strictly on the selection if
> there is one. Much like a text filter (yes, I know you're asking for te
On 1 mrt. 2013, at 20:45, LuKreme wrote:
> Text factories, as far as I can tell in my limited use of them, either act on
> all the text in the document, or on the selected text. Is there any way to
> make a text-factory behave like the Hard Wrap menu item? That is to say,
> operate on the cur
At 22:03 + 03/01/2013, John Delacour wrote:
>On 01/03/2013 21:06, Patrick Woolsey wrote:
>> At 12:45 -0700 03/01/2013, LuKreme wrote:
>>> If BBEdit did not have a Hard Wrap function and you had to recreate it
>>> via a text factory, would it be possible?
>>
>> Not with a text filter, though one
On 01/03/2013 22:03, I wrote:
No, Patrick, this can be done with a text filter. For example:
#!/usr/bin/perl
use strict;
use Text::Wrap;
$Text::Wrap::columns = 72;
my @text;
while (<>) { push @text, $_ }
print wrap('', '', @text);
or more simply
#!/usr/bin/perl
use strict;
use Text::Wrap;
On 01/03/2013 21:06, Patrick Woolsey wrote:
At 12:45 -0700 03/01/2013, LuKreme wrote:
If BBEdit did not have a Hard Wrap function and you had to recreate it
via a text factory, would it be possible?
Not with a text filter, though one could do this with a suitable script.
No, Patrick, this can
At 12:45 -0700 03/01/2013, LuKreme wrote:
>Text factories, as far as I can tell in my limited use of them, either
>act on all the text in the document, or on the selected text.
If you mean employing a text factory as a _text filter_[1], that's correct,
and these same conditions apply to every type
Text factories, as far as I can tell in my limited use of them, either act on
all the text in the document, or on the selected text. Is there any way to make
a text-factory behave like the Hard Wrap menu item? That is to say, operate on
the current line/paragraph if nothing is selected?
If BBEd