【EverEdit用户手册】Application >> AddTemplate

 

 

1 Application >> AddTemplate

添加新建文件模板

原型:

void AddTemplate(string strTitle, string strType, string strFile, bool bRunAsSnippet);

1.1 参数

strTitle

 [in] string类型, 新建模板的标题

strType

 [in] string类型, 文档类型,比如:AWK

strFile

 [in] string类型, 模板文件名,模板必须放在EverEdit的template目录,文件名不需要带目录

bRunAsSnippet

 [in] bool类型, 是否按代码片段处理,比如:模板文件中如果有$1标记,创建文件后会将鼠标停留在这个位置

1.2 返回值

void:无返回值

1.3 版本

EverEdit 4.5.0(4500)及之后版本。

1.4 备注

  

1.5 使用样例

 AddTemplate("AWK模板", "AWK", "template.awk", true);  //在新建菜单下创建“AWK模板”选项。
posted @ 2024-12-12 23:28  tyysoft  阅读(11)  评论(0)    收藏  举报