summaryrefslogtreecommitdiff
path: root/tools/editor
diff options
context:
space:
mode:
authorreduz <reduzio@gmail.com>2014-05-12 15:17:27 -0300
committerreduz <reduzio@gmail.com>2014-05-12 15:17:27 -0300
commit45a509282e912d85c46b40974a2deb926be5be42 (patch)
tree3a1313e2bad65a5d53fe39f5a961660072d6dfc0 /tools/editor
parent8905be042d4c0a28c58b317b603e9545e8ee9c12 (diff)
parent26146319315db1af9075fafa42d74f29dc73031b (diff)
Merge pull request #409 from marynate/PR-help-seach-exact-method
Use simple pattern '.METHOD' or 'METHOD(' to search method in Search Class Dialog
Diffstat (limited to 'tools/editor')
-rw-r--r--tools/editor/editor_help.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/tools/editor/editor_help.cpp b/tools/editor/editor_help.cpp
index ddbc8ee479..0471d62d16 100644
--- a/tools/editor/editor_help.cpp
+++ b/tools/editor/editor_help.cpp
@@ -123,8 +123,10 @@ void EditorHelpSearch::_update_search() {
cicon=def_icon;
for(int i=0;i<c.methods.size();i++) {
-
- if (c.methods[i].name.findn(term)!=-1) {
+ if( (term.begins_with(".") && c.methods[i].name.begins_with(term.right(1)))
+ || (term.ends_with("(") && c.methods[i].name.ends_with(term.left(term.length()-1).strip_edges()))
+ || (term.begins_with(".") && term.ends_with("(") && c.methods[i].name==term.substr(1,term.length()-2).strip_edges())
+ || c.methods[i].name.findn(term)!=-1) {
TreeItem *item = search_options->create_item(root);
item->set_metadata(0,"class_method:"+E->key()+":"+c.methods[i].name);