Reference Manual
Inti Logo
Main Page | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Namespace Members | Compound Members | File Members

viewport.h

Go to the documentation of this file.
00001 /*  Inti: Integrated Foundation Classes
00002  *  Copyright (C) 2002 The Inti Development Team.
00003  *  Copyright (C) 2000 Red Hat, Inc.
00004  *
00005  *  This program is free software; you can redistribute it and/or modify
00006  *  it under the terms of the GNU General Public License as published by
00007  *  the Free Software Foundation; either version 2 of the License, or
00008  *  (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 Library General Public License for more details.
00014  *
00015  *  You should have received a copy of the GNU Library General Public License
00016  *  along with this program; if not, write to the Free Software
00017  *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
00018  */
00019  
00025 
00026 #ifndef INTI_GTK_VIEWPORT_H
00027 #define INTI_GTK_VIEWPORT_H
00028 
00029 #ifndef INTI_GTK_BIN_H
00030 #include <inti/gtk/bin.h>
00031 #endif
00032 
00033 #ifndef __GTK_VIEWPORT_H__
00034 #include <gtk/gtkviewport.h>
00035 #endif
00036 
00037 namespace Inti {
00038 
00039 namespace Gtk {
00040 
00041 class ViewportClass;
00042 
00050 
00051 class Viewport : public Bin
00052 {
00053         friend class G::Object;
00054         friend class ViewportClass;
00055 
00056         Viewport(const Viewport&);
00057         Viewport& operator=(const Viewport&);
00058 
00059 protected:
00062 
00063         explicit Viewport(GtkViewport *viewport, bool reference = false);
00070         
00074 
00075         virtual void on_set_scroll_adjustments(Adjustment *hadjustment, Adjustment *vadjustment);
00079         
00081 //  Properties
00082 
00083         typedef G::Property<Adjustment*, G::Object*> HAdjustmentPropertyType;
00084         typedef G::PropertyProxy<G::Object, HAdjustmentPropertyType> HAdjustmentPropertyProxy;
00085         static const HAdjustmentPropertyType hadjustment_property;
00086 
00087         typedef G::Property<Adjustment*, G::Object*> VAdjustmentPropertyType;
00088         typedef G::PropertyProxy<G::Object, VAdjustmentPropertyType> VAdjustmentPropertyProxy;
00089         static const VAdjustmentPropertyType vadjustment_property;
00090 
00091         typedef G::Property<ShadowType, int> ShadowTypePropertyType;
00092         typedef G::PropertyProxy<G::Object, ShadowTypePropertyType> ShadowTypePropertyProxy;
00093         static const ShadowTypePropertyType shadow_type_property;
00094 
00095 //  Signals
00096 
00097         typedef G::Signal2<void, GtkAdjustment*, GtkAdjustment*> SetScrollAdjustmentsSignalType;
00098         typedef G::SignalProxy<TypeInstance, SetScrollAdjustmentsSignalType> SetScrollAdjustmentsSignalProxy;
00099         static const SetScrollAdjustmentsSignalType set_scroll_adjustments_signal;
00100 
00101 public:
00104 
00105         Viewport();
00107 
00108         Viewport(Adjustment *hadjustment, Adjustment *vadjustment);
00112         
00113         virtual ~Viewport();
00115         
00119 
00120         GtkViewport* gtk_viewport() const { return (GtkViewport*)instance; }
00122         
00123         GtkViewportClass* gtk_viewport_class() const;
00125         
00126         operator GtkViewport* () const;
00128 
00129         Adjustment* get_hadjustment() const;
00132 
00133         Adjustment* get_vadjustment() const;
00136 
00137         ShadowType get_shadow_type() const;
00139 
00143 
00144         void set_hadjustment(Adjustment *adjustment);
00147                 
00148         void set_vadjustment(Adjustment *adjustment);
00151         
00152         void set_shadow_type(ShadowType type);
00155         
00159         
00160         const HAdjustmentPropertyProxy prop_hadjustment()
00161         {
00162                 return HAdjustmentPropertyProxy(this, &hadjustment_property);
00163         }
00166 
00167         const VAdjustmentPropertyProxy prop_vadjustment()
00168         {
00169                 return VAdjustmentPropertyProxy(this, &vadjustment_property);
00170         }
00173 
00174         const ShadowTypePropertyProxy prop_shadow_type()
00175         {
00176                 return ShadowTypePropertyProxy(this, &shadow_type_property);
00177         }
00179         
00183         
00184         const SetScrollAdjustmentsSignalProxy sig_set_scroll_adjustments()
00185         {
00186                 return SetScrollAdjustmentsSignalProxy(this, &set_scroll_adjustments_signal);
00187         }
00190         
00192 };
00193 
00194 } // namespace Gtk
00195 
00196 } // namespace Inti
00197 
00198 #endif // INTI_GTK_VIEWPORT_H
00199 
Main Page - Footer


Generated on Sun Sep 14 20:08:05 2003 for Inti by doxygen 1.3.2 written by Dimitri van Heesch, © 1997-2002