Skip to main content

如何使用 SourceInsight 搜索功能

搜索菜单简介

Search(菜单栏)

The Search command searches the current file or selection for a specified pattern.

"搜索"命令在当前文件或所选内容中查找指定的模式。

Find

Add the pattern you want to search for in this text box.

在此文本框中添加要搜索的内容。

Search

Click this to begin searching.

点击开始搜索

Cancel

Click this to cancel the command.

点击关闭

Whole File

Click this button to search the whole file, from top to bottom, and place the search results in the Search Results window.

单击此按钮可以从上到下搜索整个文件,并将搜索结果放在“搜索结果”窗口中。

Files

Click this button to open the Search Files dialog box, which lets you search across files.

单击此按钮可打开“搜索文件”对话框,该对话框允许您跨文件进行搜索。

Case Sensitive

Search will only find matches if the case matches exactly.

只有当大小写完全匹配时,搜索才会找到匹配项。

Use Regular Expressions

The Find pattern is assumed a regular expression.

使用正则表达式

Wrap Around

If enabled, the search continues at the beginning of the file when it reaches the end of the file. The search will wrap around only once. If not enabled, the search stops when it reaches the end of the file.

如果启用,则在到达文件末尾时从文件的开头继续搜索。搜索只会绕一次。如果未启用,则搜索在到达文件末尾时停止。

补充说明:启用的话会往复循环找到的结果;不启用则到头或者到尾部会停下,并且会发出提示音;默认关闭以提醒搜索到位。

Select When Found

If enabled, Source Insight will select any characters that match when a match is found. If not enabled, Source Insight will put the insertion point before the first character of the matching text.

如果启用,Source Insight 将在找到匹配时选择任何匹配的字符。如果未启用,Source Insight 将把插入点放在匹配文本的第一个字符之前

Whole Words Only

If enabled, then Source Insight only finds matches that are whole words. If not enabled, then Source Insight will also find matches that are embedded in words.

如果启用,Source Insight 将只查找完整单词的匹配项。如果没有启用,Source Insight 也会找到嵌入在单词中的匹配项。

补充说明:启用的话只会匹配和当前输入字符串完全匹配的单词(有空格);不启用则会匹配当前输入搜索的字符串是某个单词的一部分;例如输入 na,如果开启只能搜索到 na ,关闭才能搜索到 name。

Search Scope

This group of options specifies the scope and the direction of the search.

这组选项指定了搜索的范围和方向。

Forward

Searches forward starting at the current selection. The search is always forward if Selection or Whole File is checked.

从当前选择开始向前搜索。如果选中了“选择”或“整个文件”,则搜索始终向前进行。

Backward

Searches backwards starting at the current selection.

从当前选择项开始向后搜索。

Selection

Searches only the current selection, in the forward direction.

在前进方向上仅搜索当前选择。

Whole File

Searches the whole file, in the forward direction.

在向前的方向上搜索整个文件。

If neither Selection nor Whole File is checked, then the search continues from the current selection point, either forward or backwards through the file.

如果既没有选中“选择”,也没有选中“整个文件”,则从当前选择点继续搜索,向前或向后遍历文件。