00001 /* -*- mode: C++; tab-width: 4; c-basic-offset: 4; -*- */ 00002 00003 /* AbiWord 00004 * Copyright (C) 2001 AbiSource, Inc. 00005 * 00006 * This program is free software; you can redistribute it and/or 00007 * modify it under the terms of the GNU General Public License 00008 * as published by the Free Software Foundation; either version 2 00009 * of the License, or (at your option) any later version. 00010 * 00011 * This program is distributed in the hope that it will be useful, 00012 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00014 * GNU General Public License for more details. 00015 * 00016 * You should have received a copy of the GNU General Public License 00017 * along with this program; if not, write to the Free Software 00018 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 00019 * 02110-1301 USA. 00020 */ 00021 00022 #ifndef IE_EXP_KWORD_1_H 00023 #define IE_EXP_KWORD_1_H 00024 00025 #include "ie_exp.h" 00026 #include "pl_Listener.h" 00027 00028 #define IE_MIMETYPE_KWord "application/vnd.kde.kword" 00029 00030 class PD_Document; 00031 class s_KWord_1_Listener; 00032 00033 // The exporter/writer for the KWord 1 spec 00034 00035 class IE_Exp_KWord_1_Sniffer : public IE_ExpSniffer 00036 { 00037 friend class IE_Exp; 00038 00039 public: 00040 IE_Exp_KWord_1_Sniffer (const char * name); 00041 virtual ~IE_Exp_KWord_1_Sniffer () {} 00042 00043 UT_Confidence_t supportsMIME (const char * szMIME); 00044 00045 virtual bool recognizeSuffix (const char * szSuffix); 00046 virtual bool getDlgLabels (const char ** szDesc, 00047 const char ** szSuffixList, 00048 IEFileType * ft); 00049 virtual UT_Error constructExporter (PD_Document * pDocument, 00050 IE_Exp ** ppie); 00051 }; 00052 00053 class IE_Exp_KWord_1 : public IE_Exp 00054 { 00055 public: 00056 IE_Exp_KWord_1(PD_Document * pDocument); 00057 virtual ~IE_Exp_KWord_1(); 00058 00059 protected: 00060 virtual UT_Error _writeDocument(void); 00061 00062 private: 00063 s_KWord_1_Listener * m_pListener; 00064 }; 00065 00066 #endif /* IE_EXP_KWORD_1_H */