A couple of Ideas (requirements?)
Posted: Wed Jan 11, 2006 12:46 am
Hello, everybody:
First of all, I have Search/Find/Read many threads in the forum about Macro-Support.
I have a couple of Ideas that may be somewhat cheaper to implement and may help to bring us all (the users) some of the functionality of a macro-language.
=== Use a (scripted)Tool instead of a macro ===
A solution may be the use of a Tool instead of a Macro.
But right now, the Tool creation right now is somewhat difficult (to the average user) because the tool needs to be a .exe
One alternative is that Textpad have the ability to Invoque a Script-Engine and execute some Code, and let that Code to process the <selected-text> or the <full-text> of the file that is being processed.
The Script-Code could "live" in the Clip-Library. Right now the options of a Clip is [Replace-Selection (on/off)]; the options could be enhanced to have an [Script Code] option in order to let TextPad Identify that that Clip is actually a Script Code, and Textpad could Call the Configurated Script-Engine and Execute the Code contained in the Clip, passing the configured arguments and the <selected-text>
Maybe Textpad could have a Configuration entry to Define the executable to Call (just like the Tools), and with that the users can select any Script-Engine installed in their Machines. Another posibility of that is the use of an Alternate Language like AWK; and Textpad would execute AWK (just like any other Script-Engine) and let AWK execute the Clip and receive the arguments.
Saludos
Alex
First of all, I have Search/Find/Read many threads in the forum about Macro-Support.
I have a couple of Ideas that may be somewhat cheaper to implement and may help to bring us all (the users) some of the functionality of a macro-language.
=== Use a (scripted)Tool instead of a macro ===
A solution may be the use of a Tool instead of a Macro.
But right now, the Tool creation right now is somewhat difficult (to the average user) because the tool needs to be a .exe
One alternative is that Textpad have the ability to Invoque a Script-Engine and execute some Code, and let that Code to process the <selected-text> or the <full-text> of the file that is being processed.
The Script-Code could "live" in the Clip-Library. Right now the options of a Clip is [Replace-Selection (on/off)]; the options could be enhanced to have an [Script Code] option in order to let TextPad Identify that that Clip is actually a Script Code, and Textpad could Call the Configurated Script-Engine and Execute the Code contained in the Clip, passing the configured arguments and the <selected-text>
Maybe Textpad could have a Configuration entry to Define the executable to Call (just like the Tools), and with that the users can select any Script-Engine installed in their Machines. Another posibility of that is the use of an Alternate Language like AWK; and Textpad would execute AWK (just like any other Script-Engine) and let AWK execute the Clip and receive the arguments.
Saludos
Alex