» StringReplacer Plugin (useful with Fantastick Plugin)
This site relies heavily on Javascript. You should enable it if you want the full experience. Learn more.

StringReplacer Plugin (useful with Fantastick Plugin)

plugin

about

This plugin is a generic string replacement sort-of thing.

StringReplacer.zip: Includes 3 dynamic plugins for doing string replacements. The most useful of these 3 plugins is StringReplacerSpreadable. These plugins are very useful for injecting information from your vvvv patch into your Fantastick JS code.

For Example:

Input:
Hello, my name is $1, I am feeling very $2, how about you, $3, are you $2?

Replacements:
$1 = John, $2 = happy, $3 = Bill

Output:
Hello, my name is John, I am feeling very happy, how about you, Bill, are you happy?

download

StringReplacer.zip
26.05.11 [20:48 UTC] by gilbi | 1157 downloads

antokhio 27/05/2011 - 00:20

cool one, ths gibi!

gilbi 27/05/2011 - 01:17

thanks, enjoy :)

... JS Framework for Fantastick coming soon !

kalle 31/05/2011 - 12:12

without looking into the plugins, but doesn't do Substitute (String) exactly that?

gilbi 31/05/2011 - 17:13

Thanks Kalle, that will be useful in the future. This plugin is a lot faster than Substitute when you use the Enabled pin, but obviously making a module wrapping Substitute with an Enabled pin would be very easy.

gilbi 31/05/2011 - 20:59

I take that back, not so easy in fact. Substitute is not spreadable in the same way that StringReplacerSpreadable is.

bjoern 01/06/2011 - 00:30

I also haven´t had a look at it :) But what comes to mind when reading the description is vux & dep´s
RegExpr (String Replace).

gilbi 01/06/2011 - 00:56

I was actually using RegExpr before I created this module. Similar problems are involved with RegExpr as far as spread-ability and possibly performance as well.

bjoern 01/06/2011 - 11:44

Concerning speed and spread-ability, hard to tell since there is no help patch that shows the intended use.

antokhio 09/10/2012 - 01:20

it's possible do modif this so we have custom string instead of $1 $2 since
i need to rewrite file but string might be different like 4- launchpad replace with launchpad... something like that

anonymous user login

Shoutbox

~3mth ago

joreg: END OF SHOUTBOX! As this page has is now legacy, it will no longer feature new content. For latest news, see: http://vvvv.org

~4mth ago

joreg: vvvvTv S0204 is out: Custom Widgets with Dear ImGui: https://youtube.com/live/nrXfpn5V9h0

~4mth ago

joreg: New user registration is currently disabled as we're moving to a new login provider: https://visualprogramming.net/blog/2024/reclaiming-vvvv.org/

~4mth ago

joreg: vvvvTv S02E03 is out: Logging: https://youtube.com/live/OpUrJjTXBxM

~5mth ago

~5mth ago

joreg: Follow TobyK on his Advent of Code: https://www.twitch.tv/tobyklight

~5mth ago

joreg: vvvvTv S02E02 is out: Saving & Loading UI State: https://www.youtube.com/live/GJQGVxA1pIQ

~5mth ago

joreg: We now have a presence on LinkedIn: https://www.linkedin.com/company/vvvv-group

~5mth ago

joreg: vvvvTv S02E01 is out: Buttons & Sliders with Dear ImGui: https://www.youtube.com/live/PuuTilbqd9w

~5mth ago

joreg: vvvvTv S02E00 is out: Sensors & Servos with Arduino: https://visualprogramming.net/blog/2024/vvvvtv-is-back-with-season-2/