#include <barbarisms.h>
Public Member Functions | |
BarbarismChecker () | |
~BarbarismChecker () | |
bool | load (const char *szLang) |
bool | checkWord (const UT_UCSChar *word32, size_t length) |
True if word is a barbarsim, false if not. | |
bool | suggestWord (const UT_UCSChar *word32, size_t length, UT_GenericVector< UT_UCSChar * > *pVecsugg) |
void | startElement (const gchar *name, const gchar **atts) |
void | endElement (const gchar *) |
void | charData (const gchar *, int) |
Private Member Functions | |
bool | suggestExactWord (const UT_UCSChar *word32, size_t length, UT_GenericVector< UT_UCSChar * > *pVecsugg) |
Private Attributes | |
UT_GenericStringMap < UT_GenericVector < UT_UCS4Char * > * > | m_map |
UT_GenericVector< UT_UCS4Char * > * | m_pCurVector |
UT_String | m_sLang |
BarbarismChecker::BarbarismChecker | ( | ) |
References m_pCurVector.
BarbarismChecker::~BarbarismChecker | ( | ) |
References m_map.
void BarbarismChecker::charData | ( | const gchar * | , | |
int | ||||
) | [inline, virtual] |
Implements UT_XML::Listener.
bool BarbarismChecker::checkWord | ( | const UT_UCSChar * | word32, | |
size_t | length | |||
) |
True if word is a barbarsim, false if not.
References UT_UTF8String::appendUCS4(), m_map, UT_GenericStringMap< T >::pick(), and UT_UTF8String::utf8_str().
Referenced by SpellChecker::checkWord().
void BarbarismChecker::endElement | ( | const gchar * | ) | [inline, virtual] |
Implements UT_XML::Listener.
bool BarbarismChecker::load | ( | const char * | szLang | ) |
References UT_String::c_str(), XAP_App::getApp(), m_map, m_sLang, UT_XML::parse(), UT_XML::setListener(), UT_GenericStringMap< T >::size(), and UT_DEBUGMSG.
Referenced by SpellChecker::requestDictionary().
void BarbarismChecker::startElement | ( | const gchar * | name, | |
const gchar ** | atts | |||
) | [virtual] |
bool BarbarismChecker::suggestExactWord | ( | const UT_UCSChar * | word32, | |
size_t | length, | |||
UT_GenericVector< UT_UCSChar * > * | pVecsugg | |||
) | [private] |
bool BarbarismChecker::suggestWord | ( | const UT_UCSChar * | word32, | |
size_t | length, | |||
UT_GenericVector< UT_UCSChar * > * | pVecsugg | |||
) |
UT_GenericStringMap<UT_GenericVector<UT_UCS4Char *>*> BarbarismChecker::m_map [private] |
Referenced by checkWord(), load(), startElement(), suggestExactWord(), and ~BarbarismChecker().
UT_GenericVector<UT_UCS4Char *>* BarbarismChecker::m_pCurVector [private] |
Referenced by BarbarismChecker(), and startElement().
UT_String BarbarismChecker::m_sLang [private] |
Referenced by load().