最近搞试卷库,程序设计的,很多题目的选项,分号,引号等都不对,于是在EmEditor中进行替换
1. 程序分析和填空
document.selection.Replace(")",")",eeFindNext | eeReplaceAll);
document.selection.Replace("(","(",eeFindNext | eeReplaceAll);
document.selection.Replace("’","\x27",eeFindNext | eeReplaceAll);
document.selection.Replace("‘","\x27",eeFindNext | eeReplaceAll);
document.selection.Replace("”","\x22",eeFindNext | eeReplaceAll);
document.selection.Replace("“","\x22",eeFindNext | eeReplaceAll);
document.selection.Replace(",",",",eeFindNext | eeReplaceAll);
document.selection.Replace(";",";",eeFindNext | eeReplaceAll);
document.selection.Replace("_{2,}","____________________________",eeFindNext | eeReplaceAll | eeFindReplaceRegExp);
document.selection.Replace("\\s{2,}"," ",eeFindNext | eeReplaceAll | eeFindReplaceRegExp);
document.selection.Replace("\\t+"," ",eeFindNext | eeReplaceAll | eeFindReplaceRegExp);
2. 选择
document.selection.Replace("_{2,}","( )",eeFindNext | eeReplaceAll | eeFindReplaceRegExp);
document.selection.Replace("_{2,}","( )",eeFindNext | eeReplaceAll | eeFindReplaceRegExp);
document.selection.Replace(")",")",eeFindNext | eeReplaceAll);
document.selection.Replace("(","(",eeFindNext | eeReplaceAll);
document.selection.Replace("’","\x27",eeFindNext | eeReplaceAll);
document.selection.Replace("‘","\x27",eeFindNext | eeReplaceAll);
document.selection.Replace("”","\x22",eeFindNext | eeReplaceAll);
document.selection.Replace("“","\x22",eeFindNext | eeReplaceAll);
document.selection.Replace(",",",",eeFindNext | eeReplaceAll);
document.selection.Replace(";",";",eeFindNext | eeReplaceAll);
document.selection.Replace("([A-D])、","\\1. ",eeFindNext | eeFindReplaceCase | eeReplaceAll | eeFindReplaceRegExp);
document.selection.Replace("([A-D])\\)","\\1.",eeFindNext | eeFindReplaceCase | eeReplaceAll | eeFindReplaceRegExp);