From 7b7af48a7681ab335ba2c53ffa48ab053ddf4c86 Mon Sep 17 00:00:00 2001 From: nyamatongwe Date: Tue, 21 Jul 2009 09:05:43 +0000 Subject: Using a much simpler property set implementation. Accessor objects use the PropertyGet interface to access just the property set methods they need. Removed SString. --- src/CharClassify.h | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) (limited to 'src/CharClassify.h') diff --git a/src/CharClassify.h b/src/CharClassify.h index 881d3a114..d746fe02d 100644 --- a/src/CharClassify.h +++ b/src/CharClassify.h @@ -2,7 +2,7 @@ /** @file CharClassify.h ** Character classifications used by Document and RESearch. **/ -// Copyright 2006 by Neil Hodgson +// Copyright 2006-2009 by Neil Hodgson // The License.txt file describes the conditions under which this software may be distributed. #ifndef CHARCLASSIFY_H @@ -22,4 +22,16 @@ private: enum { maxChar=256 }; unsigned char charClass[maxChar]; // not type cc to save space }; + +// These functions are implemented because each platform calls them something different. +int CompareCaseInsensitive(const char *a, const char *b); +int CompareNCaseInsensitive(const char *a, const char *b, size_t len); + +inline char MakeUpperCase(char ch) { + if (ch < 'a' || ch > 'z') + return ch; + else + return static_cast(ch - 'a' + 'A'); +} + #endif -- cgit v1.2.3