Can I get rid of backslashes?
How can I have something like a textedit that doesn't interpret special characters like comma, semicolon, and double quotes? In other words can I input text and automatically escape these special characters?
So I want to type things like:
this, is, a, single, message
but have it act like:
this, is, a, single, message
And things like:
"this is four symbols"
should act like:
"this is four symbols"
I'm guessing it's not possible with the built in objects. Maybe using Swing in a Java/mxj object I can make a text input that does this? Any better ideas?
maybe this would be a job for [regexp] or [jit.str.regexp].
i am really badly versed in the regular expressions stuff but here is a patch posted by someone ( apologies to the author , i cant remember who it was ) that does the exact opposite of what you are looking for , it could lead you to the right direction .
sorry for not being more helpfull :(
Quote: Adam Murray (adamj) wrote on Sat, 09 February 2008 02:26
----------------------------------------------------
> How can I have something like a textedit that doesn't interpret special characters like comma, semicolon, and double quotes? In other words can I input text and automatically escape these special characters?
>
> So I want to type things like:
> this, is, a, single, message
> but have it act like:
> this, is, a, single, message
>
> And things like:
> "this is four symbols"
> should act like:
> "this is four symbols"
>
> I'm guessing it's not possible with the built in objects. Maybe using Swing in a Java/mxj object I can make a text input that does this? Any better ideas?
>
>
----------------------------------------------------
regexp object. See perl syntax on how to do thi.
Best wishes,
Ico
> -----Original Message-----
> From: maxmsp-bounces@cycling74.com [mailto:maxmsp-bounces@cycling74.com]
> On Behalf Of Adam Murray
> Sent: Friday, February 08, 2008 8:27 PM
> Subject: [maxmsp] Can I get rid of backslashes?
>
>
> How can I have something like a textedit that doesn't interpret special
> characters like comma, semicolon, and double quotes? In other words can I
> input text and automatically escape these special characters?
>
> So I want to type things like:
> this, is, a, single, message
> but have it act like:
> this, is, a, single, message
>
> And things like:
> "this is four symbols"
> should act like:
> "this is four symbols"
>
> I'm guessing it's not possible with the built in objects. Maybe using
> Swing in a Java/mxj object I can make a text input that does this? Any
> better ideas?
>
>
> --
> Adam Murray
> compusition.com
Thanks for the replies.
regexp would work, but is there a way to do a replace all when substituting? Something equivalent to the 'g' (global) option in standard/Perl regex? I can replace a comma with backslash comma but it only replaces one comma:
I guess I'd have to loop the operation until the regexp doesn't match anymore.
Anyway, I somehow overlooked the "Output as One Symbol" option in textedit's inspector. That mostly solves my problems so I'm just going to use that for now.