我使用EditPlus 3.30作为我的代码编辑器,但这个问题也适用于早期版本。我想在用户工具栏上创建一个新的用户工具项。默认设置允许您在单击图标时打开模板。我想创建一个项目,而不是粘贴来自libray文件(* .ctl)或任何其他文本文件的代码。最后,新用户工具项的功能就像hml工具栏上的一个图标一样。
我没有丰富的编程经验。
答案 0 :(得分:0)
EditPlus文本编辑器:如何创建工具栏用户工具图标以粘贴自定义代码段。
配置“首选项/工具”对话框,如下所示:
Command CScript.exe C:\Your Path\Pastetext.js Argument //NoLogo $(CurRow) leave initial directory blank Action Run as text (Insert)
将流动的五行保存为Pastetext.js
var cArgs = WScript.Arguments; var rStr = cArgs(0); var rStr ="<item id='file1' media-type='application/xhtml+xml' href='aSample.html'/>"; // Print filler string WScript.StdOut.Write(rStr);
// rStr
变量将打印光标在打开文档中的位置。