Scite 查找所有出现项

lua-users home
wiki

本条目没有脚本,这是我的实现。

输出应类似于 grep 或 findstr 的输出,因此 F4 'Next Message' 应按预期工作。


function SciteListAllOccurances()
  if props.CurrentSelection ~= "" then
    for m in editor:match( "^.*" .. props.CurrentSelection .. ".*$", SCFIND_REGEXP, 0) do
      print(props.FileNameExt .. ":" .. (editor:LineFromPosition(m.pos)+1) .. ":" .. m.text);
    end
  else
    alert("The InternalGrep script only searchs for selected text");
  end
end
-- April White, 2006年1月21日
RecentChanges · preferences
编辑 · 历史
最后编辑于 2006年8月31日 下午2:38 GMT (差异)