• Main Page
  • Related Pages
  • Namespaces
  • Classes
  • Files
  • File List
  • File Members

xap_QtApp.h

Go to the documentation of this file.
00001 /* -*- mode: C++; tab-width: 4; c-basic-offset: 4; -*- */
00002 /* AbiSource Application Framework
00003  * Copyright (C) 2012 Hubert Figuiere
00004  *
00005  * This program is free software; you can redistribute it and/or
00006  * modify it under the terms of the GNU General Public License
00007  * as published by the Free Software Foundation; either version 2
00008  * of the License, or (at your option) any later version.
00009  *
00010  * This program is distributed in the hope that it will be useful,
00011  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00012  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00013  * GNU General Public License for more details.
00014  *
00015  * You should have received a copy of the GNU General Public License
00016  * along with this program; if not, write to the Free Software
00017  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
00018  * 02110-1301 USA.
00019  */
00020 
00021 #ifndef __XAP_QT_APP_H__
00022 #define __XAP_QT_APP_H__
00023 
00024 #ifdef HAVE_CONFIG_H
00025 #include "config.h"
00026 #endif
00027 
00028 #include "xap_App.h"
00029 #include "xap_Qt_TB_CFactory.h"
00030 #include "xap_QtDialogFactory.h"
00031 
00032 class QApplication;
00033 
00034 class ABI_EXPORT XAP_QtApp
00035     : public XAP_App
00036 {
00037 public:
00038     XAP_QtApp(const char*);
00039     virtual ~XAP_QtApp();
00040 
00041     virtual const char * getDefaultEncoding () const
00042     { return "UTF-8"; }
00043 
00044     virtual void                            reallyExit();
00045     virtual XAP_DialogFactory *             getDialogFactory()
00046     { return &m_dialogFactory; }
00047     virtual XAP_Toolbar_ControlFactory *    getControlFactory()
00048     { return &m_controlFactory; }
00049     virtual const char *                    getUserPrivateDirectory() const;
00050 
00051 protected:
00052     int exec(); // QApplication Exec.
00053 
00054     void                            _setAbiSuiteLibDir();
00055 
00056     XAP_QtDialogFactory         m_dialogFactory;
00057     AP_QtToolbar_ControlFactory m_controlFactory;
00058 
00059     QApplication* m_app;
00060 
00061 private:
00062     int m_qtArgc;
00063     const char* m_qtArgv;
00064 };
00065 
00066 #endif
00067 

Generated on Sun Feb 14 2021 for AbiWord by  doxygen 1.7.1