summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2016-06-30 07:57:31 +0200
committerGitHub <noreply@github.com>2016-06-30 07:57:31 +0200
commitfcf6977610aa197bbe9a044b536e008084531670 (patch)
tree4e2a5d219e56941965c8cad3f1f92d8e5e8c6115
parentcf0fbe493ff8e2dd80859d75a9794d364a03551c (diff)
parent484f4d8dec3ad1f08a3a5d36d6eb59cdfd9ad7d8 (diff)
Merge pull request #5487 from Paulb23/function_highlighting_issue_5454
Fixed function highlighting with spaces
-rw-r--r--scene/gui/text_edit.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/scene/gui/text_edit.cpp b/scene/gui/text_edit.cpp
index 8176c070ef..3adf129ce5 100644
--- a/scene/gui/text_edit.cpp
+++ b/scene/gui/text_edit.cpp
@@ -852,6 +852,11 @@ void TextEdit::_notification(int p_what) {
k++;
}
+ // check for space between name and bracket
+ while (k < str.length() && (str[k] == '\t' || str[k] == ' ')) {
+ k++;
+ }
+
if (str[k] == '(') {
in_function_name = true;
}