blueharmony:
--------------------------------------------------------------------------------
...I want to create a macro that, after i select text, Joins The lines, and then
copies the selected text to the clipboard.
It appears that the macro recorder can't record the "join lines" command in the
Edit/Lines Manipulation menu.
-Marc
--------------------------------------------------------------------------------
Hi,
the macro functionality is rather limited in some aspects; there is much more
powerful scripting support in PSPad.
An equivalent script might be:
cite:
--------------------------------------------------------------------------------
//// ... PSPad\Script\JScrip\joinCopy.js //////////
var module_name = "joinCopy";
var module_ver = "1";
function joinAndCopy(){
if (editorsCount()<1){return;}
var actEd = newEditor();
actEd.assignActiveEditor();
runPSPadAction("aJoinLine");
actEd.command("ecLineStart");
actEd.command("ecSelLineEnd");
runPSPadAction("aCopy");
}
function Init(){
addMenuItem("join and copy", "", "joinAndCopy","Ctrl+Alt+Shift+J");
}
--------------------------------------------------------------------------------
You can adjust the shortcut to some suitable (not colliding one).
The source can just be saved as a file in PSPad\script\JScrip\joinCopy.js
After calling Scripts: Recompile form the menu the the menu item and shortcut
should be available (supposing the activated WSH support in the "System
integration" settings).
Check the file
...\PSPad\Script\readme.rtf
for other possible commands you may need for other functions.
hth,
vbr
--
<http://forum.pspad.com/read.php?2,50914,50923>
PSPad freeware editor http://www.pspad.com