diff --git a/honoka/libhonoka/Makefile.am b/honoka/libhonoka/Makefile.am index 2d2e62d..d1b0d86 100644 --- a/honoka/libhonoka/Makefile.am +++ b/honoka/libhonoka/Makefile.am @@ -25,19 +25,19 @@ -DHONOKA_ICON_FILE=\"@SCIM_ICONDIR@/honoka.png\" \ -DHONOKA_PLUGINDIR=\"@SCIM_MODULEDIR@/honoka\" -noinst_HEADERS = + moduledir = @SCIM_MODULEDIR@/IMEngine libhonokaincludedir = $(includedir)/honoka libhonokainclude_HEADERS = convertor.h preeditor.h honokapluginbase.h \ - honokakeyeventlist.h honokamultiplepluginbase.h predictor.h \ - resultlist.h honokatimer.h honokasetupcore.h + honokakeyeventlist.h honokamultiplepluginbase.h predictor.h resultlist.h honokatimer.h \ + honokasetupcore.h honokastatus.h lib_LTLIBRARIES = libhonoka_plugin.la libhonoka_plugin_la_SOURCES = convertor.cpp honokapluginbase.cpp preeditor.cpp \ - honokakeyeventlist.cpp honokamultiplepluginbase.cpp predictor.cpp resultlist.cpp \ - honokatimer.cpp honokasetupcore.cpp + honokakeyeventlist.cpp honokamultiplepluginbase.cpp predictor.cpp resultlist.cpp \ + honokatimer.cpp honokasetupcore.cpp honokastatus.cpp libhonoka_plugin_la_CFLAGS = @SCIM_CFLAGS@ @SCIM_DEBUG_FLAGS@ libhonoka_plugin_la_CXXFLAGS = @SCIM_CFLAGS@ @SCIM_DEBUG_FLAGS@ libhonoka_plugin_la_LDFLAGS = @LIBTOOL_EXPORT_OPTIONS@ @INTLLIBS@ @SCIM_LIBS@ diff --git a/honoka/libhonoka/honokastatus.cpp b/honoka/libhonoka/honokastatus.cpp new file mode 100644 index 0000000..ba311db --- /dev/null +++ b/honoka/libhonoka/honokastatus.cpp @@ -0,0 +1,64 @@ +/*************************************************************************** + * Copyright (C) 2005 by TAM(Teppei Tamra) * + * tam-t@par.odn.ne.jp * + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * (at your option) any later version. * + * * + * This program is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * + * GNU General Public License for more details. * + * * + * You should have received a copy of the GNU General Public License * + * along with this program; if not, write to the * + * Free Software Foundation, Inc., * + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * + ***************************************************************************/ + +#include "honokastatus.h" + +using namespace Honoka; + +HonokaStatus::HonokaStatus() +{ +} + + +HonokaStatus::~HonokaStatus() +{ +} + +bool HonokaStatus::m_conversion = false; +bool HonokaStatus::m_prediction = false; +bool HonokaStatus::m_lookup = false; + + + +/*! + \fn Honoka::HonokaStatus::getConvertionStatus() + */ +bool Honoka::HonokaStatus::getConvertionStatus() +{ + return m_conversion; +} + +/*! + \fn Honoka::HonokaStatus::getPredictionStatus() + */ +bool Honoka::HonokaStatus::getPredictionStatus() +{ + return m_prediction; +} + + +/*! + \fn Honoka::HonokaStatus::getLookupStatus() + */ +bool Honoka::HonokaStatus::getLookupStatus() +{ + return m_lookup; +} + diff --git a/honoka/libhonoka/honokastatus.h b/honoka/libhonoka/honokastatus.h new file mode 100644 index 0000000..022276f --- /dev/null +++ b/honoka/libhonoka/honokastatus.h @@ -0,0 +1,44 @@ +/*************************************************************************** + * Copyright (C) 2005 by TAM(Teppei Tamra) * + * tam-t@par.odn.ne.jp * + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * (at your option) any later version. * + * * + * This program is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * + * GNU General Public License for more details. * + * * + * You should have received a copy of the GNU General Public License * + * along with this program; if not, write to the * + * Free Software Foundation, Inc., * + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * + ***************************************************************************/ + +#ifndef HONOKASTATUS_H +#define HONOKASTATUS_H + +/** + @author TAM (Teppei Tamra) +*/ +namespace Honoka { +class HonokaStatus{ +public: + HonokaStatus(); + + ~HonokaStatus(); + static bool getConvertionStatus(); + static bool getPredictionStatus(); + static bool getLookupStatus(); + +protected: + static bool m_conversion; + static bool m_prediction; + static bool m_lookup; + +}; +} +#endif diff --git a/honoka/src/honoka_imengine.h b/honoka/src/honoka_imengine.h index 3b31de3..aaac873 100644 --- a/honoka/src/honoka_imengine.h +++ b/honoka/src/honoka_imengine.h @@ -43,6 +43,7 @@ #include #include #include +#include #define Uses_SCIM_ICONV #include #include @@ -91,7 +92,7 @@ }; -class HonokaInstance : public IMEngineInstanceBase +class HonokaInstance : public IMEngineInstanceBase,public HonokaStatus { protected: friend class MultiConvertor; @@ -120,9 +121,9 @@ Convertor *m_convertor; Convertor *m_def_convertor; Predictor *m_predictor; - bool m_conversion; - bool m_prediction; - bool m_lookup; + //bool m_conversion; + //bool m_prediction; + //bool m_lookup; ResultList m_convList; ResultList m_convListOrig; PropertyList m_proplist;