aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorNeil <nyamatongwe@gmail.com>2019-11-02 08:44:24 +1100
committerNeil <nyamatongwe@gmail.com>2019-11-02 08:44:24 +1100
commit9258708542f5d7184620d8e2e4e3aed966182b72 (patch)
tree71cef4348eb1b76fe9bb1aea0c9be1cd97f9999b
parent0777bb261f970bfb6c7cde06544630df37024322 (diff)
downloadscintilla-mirror-9258708542f5d7184620d8e2e4e3aed966182b72.tar.gz
Feature [feature-requests:#1320] Fix non-alphabetic characters in unknown tags.
-rw-r--r--doc/ScintillaHistory.html4
-rw-r--r--lexers/LexHTML.cxx3
2 files changed, 6 insertions, 1 deletions
diff --git a/doc/ScintillaHistory.html b/doc/ScintillaHistory.html
index 1bb21f6d3..e9ff2cf58 100644
--- a/doc/ScintillaHistory.html
+++ b/doc/ScintillaHistory.html
@@ -571,6 +571,10 @@
<a href="https://sourceforge.net/p/scintilla/feature-requests/1317/">Feature #1317</a>.
</li>
<li>
+ HTML lexer fixes bug with some non-alphabetic characters in unknown tags.
+ <a href="https://sourceforge.net/p/scintilla/feature-requests/1320/">Feature #1320</a>.
+ </li>
+ <li>
Avoid unnecessary IME caret movement on Win32.
<a href="https://sourceforge.net/p/scintilla/feature-requests/1304/">Feature #1304</a>.
</li>
diff --git a/lexers/LexHTML.cxx b/lexers/LexHTML.cxx
index 9d9ec9bb1..795d88e07 100644
--- a/lexers/LexHTML.cxx
+++ b/lexers/LexHTML.cxx
@@ -286,10 +286,11 @@ int classifyTagHTML(Sci_PositionU start, Sci_PositionU end,
char chAttr = SCE_H_TAGUNKNOWN;
if (!tag.empty() && (tag[0] == '!')) {
chAttr = SCE_H_SGML_DEFAULT;
+ styler.ColourTo(end, chAttr);
} else if (!keywords || keywords.InList(tag.c_str())) {
chAttr = SCE_H_TAG;
+ styler.ColourTo(end, chAttr);
}
- styler.ColourTo(end, chAttr);
if (chAttr == SCE_H_TAG) {
if (allowScripts && (tag == "script")) {
// check to see if this is a self-closing tag by sniffing ahead