diff --git a/etk/UniChar.cpp b/etk/UniChar.cpp index fc378fa..20a1a4e 100644 --- a/etk/UniChar.cpp +++ b/etk/UniChar.cpp @@ -95,6 +95,17 @@ bool etk::UniChar::isWhiteChar(void) const return false; } +bool etk::UniChar::isSpecialChar(void) const +{ + if( m_value < '0' + || (m_value > '9' && m_value < 'A') + || (m_value > 'Z' && m_value < 'a') + || (m_value > 'z' && m_value < 0xFF) ) { + return true; + } + return false; +} + bool etk::UniChar::isInteger(void) const { if( m_value>=(uint32_t)'0' diff --git a/etk/UniChar.h b/etk/UniChar.h index 98934db..f057cbd 100644 --- a/etk/UniChar.h +++ b/etk/UniChar.h @@ -157,6 +157,7 @@ namespace etk * @return tue if it is white char */ bool isWhiteChar(void) const; + bool isSpecialChar(void) const; /** * @brief check if the curent element is number or not * @return tue if it is a number char