X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/e14d10b039e68a701a447043a4031cf43e9fa90b..9556c0f1b3dec367bf2bdc3eef7b1d54668adcf7:/src/stc/scintilla/include/PropSet.h diff --git a/src/stc/scintilla/include/PropSet.h b/src/stc/scintilla/include/PropSet.h index 1a7e2f1665..62cd5da3a9 100644 --- a/src/stc/scintilla/include/PropSet.h +++ b/src/stc/scintilla/include/PropSet.h @@ -24,11 +24,21 @@ struct Property { /** */ class PropSet { -private: +protected: enum { hashRoots=31 }; Property *props[hashRoots]; Property *enumnext; int enumhash; + static unsigned int HashString(const char *s, size_t len) { + unsigned int ret = 0; + while (len--) { + ret <<= 4; + ret ^= *s; + s++; + } + return ret; + } + static bool IncludesVar(const char *value, const char *key); public: PropSet *superPS; PropSet(); @@ -71,7 +81,7 @@ public: void SetFromAllocated(); bool InList(const char *s); const char *GetNearestWord(const char *wordStart, int searchLen = -1, - bool ignoreCase = false, SString wordCharacters=""); + bool ignoreCase = false, SString wordCharacters="", int wordIndex = -1); char *GetNearestWords(const char *wordStart, int searchLen=-1, bool ignoreCase=false, char otherSeparator='\0'); };