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

ap_UnixFrameImpl.h

Go to the documentation of this file.
00001 /* AbiWord
00002  * Copyright (C) 1998 AbiSource, Inc.
00003  * Copyright (C) 2002 William Lachance
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 AP_UNIXFRAMEIMPL_H
00022 #define AP_UNIXFRAMEIMPL_H
00023 #include "xap_Frame.h"
00024 #include "ap_Frame.h"
00025 #include "ap_UnixFrame.h"
00026 #include "ie_types.h"
00027 #include "xap_UnixFrameImpl.h"
00028 #include "ap_DocView.h"
00029 
00030 
00031 class XAP_UnixApp;
00032 class AP_UnixFrame;
00033 
00034 enum apufi_ScrollType { apufi_scrollX, apufi_scrollY }; // can we use namespaces yet? this is quite ugly
00035 
00036 class AP_UnixFrameImpl : public XAP_UnixFrameImpl
00037 {
00038  public:
00039     AP_UnixFrameImpl(AP_UnixFrame *pUnixFrame);
00040     virtual XAP_FrameImpl * createInstance(XAP_Frame *pFrame);
00041 
00042     virtual UT_RGBColor getColorSelBackground () const;
00043     virtual UT_RGBColor getColorSelForeground () const;
00044 
00045     GtkShadowType getShadowType () { return gtk_frame_get_shadow_type (GTK_FRAME (m_wSunkenBox)); }
00046     void setShadowType (GtkShadowType shadow) { gtk_frame_set_shadow_type (GTK_FRAME (m_wSunkenBox), shadow); }
00047 
00048     GtkWidget * getDrawingArea() const {return m_dArea;}
00049     static gboolean ap_focus_in_event (GtkWidget * drawing_area, GdkEventCrossing *event, AP_UnixFrameImpl * me);
00050     static gboolean ap_focus_out_event (GtkWidget * drawing_area, GdkEventCrossing *event, AP_UnixFrameImpl * me);
00051     virtual GtkWidget * getViewWidget(void) const
00052     { return m_dArea; }
00053 
00054  protected:
00055     friend class AP_UnixFrame;
00056     void _showOrHideStatusbar(void);
00057     void _showOrHideToolbars(void);
00058 
00059     virtual void _hideMenuScroll(bool bHideMenuScroll);
00060 
00061 
00062     virtual void _refillToolbarsInFrameData();
00063     void _bindToolbars(AV_View * pView);
00064     virtual void _createWindow();
00065 
00066     virtual GtkWidget * _createDocumentWindow();
00067     virtual GtkWidget * _createStatusBarWindow();
00068 
00069     virtual void _setWindowIcon();
00070     void _setScrollRange(apufi_ScrollType scrollType, int iValue, gfloat fUpperLimit, gfloat fSize);
00071 
00072     GtkWidget * m_dArea;
00073     GtkAdjustment * m_pVadj;
00074     GtkAdjustment * m_pHadj;
00075     GtkWidget * m_hScroll;
00076     GtkWidget * m_vScroll;
00077     GtkWidget * m_topRuler;
00078     GtkWidget * m_leftRuler;
00079     GtkWidget * m_grid;
00080     GtkWidget * m_innergrid;
00081     GtkWidget * m_wSunkenBox;
00082     gulong      m_iHScrollSignal;
00083     gulong      m_iVScrollSignal;
00084 };
00085 #endif

Generated on Sun Feb 14 2021 for AbiWord by  doxygen 1.7.1