| 1 |
/* Copyright (C) 2002 The gtkmm Development Team |
| 2 |
* |
| 3 |
* This library is free software; you can redistribute it and/or |
| 4 |
* modify it under the terms of the GNU Lesser General Public |
| 5 |
* License as published by the Free Software Foundation; either |
| 6 |
* version 2.1 of the License, or (at your option) any later version. |
| 7 |
* |
| 8 |
* This library is distributed in the hope that it will be useful, |
| 9 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 10 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 11 |
* Lesser General Public License for more details. |
| 12 |
* |
| 13 |
* You should have received a copy of the GNU Lesser General Public |
| 14 |
* License along with this library; if not, see <https://www.gnu.org/licenses/>. |
| 15 |
*/ |
| 16 |
|
| 17 |
#include <gtkmm/bin.h> |
| 18 |
#include <gtkmm/scrollable.h> |
| 19 |
|
| 20 |
_DEFS(gtkmm,gtk) |
| 21 |
_PINCLUDE(gtkmm/private/bin_p.h) |
| 22 |
|
| 23 |
|
| 24 |
namespace Gtk { |
| 25 |
|
| 26 |
/** An adapter which makes widgets scrollable. |
| 27 |
* |
| 28 |
* @ingroup Widgets |
| 29 |
* @ingroup Containers |
| 30 |
*/ |
| 31 |
class GTKMM_API Viewport |
| 32 |
: public Bin, |
| 33 |
public Scrollable |
| 34 |
{ |
| 35 |
_CLASS_GTKOBJECT(Viewport,GtkViewport,GTK_VIEWPORT,Gtk::Bin,GtkBin,,,GTKMM_API) |
| 36 |
_IMPLEMENTS_INTERFACE(Scrollable) |
| 37 |
public: |
| 38 |
|
| 39 |
_WRAP_CTOR(Viewport(const Glib::RefPtr<Adjustment>& hadjustment, const Glib::RefPtr<Adjustment>& vadjustment), gtk_viewport_new) |
| 40 |
|
| 41 |
|
| 42 |
_IGNORE(gtk_viewport_get_hadjustment, gtk_viewport_get_vadjustment, |
| 43 |
gtk_viewport_set_hadjustment, gtk_viewport_set_vadjustment) //deprecated |
| 44 |
|
| 45 |
_WRAP_METHOD(void set_shadow_type(ShadowType type), |
| 46 |
gtk_viewport_set_shadow_type) |
| 47 |
|
| 48 |
_WRAP_METHOD(ShadowType get_shadow_type() const, |
| 49 |
gtk_viewport_get_shadow_type) |
| 50 |
|
| 51 |
_WRAP_METHOD(Glib::RefPtr<Gdk::Window> get_bin_window(), gtk_viewport_get_bin_window, refreturn) |
| 52 |
_WRAP_METHOD(Glib::RefPtr<const Gdk::Window> get_bin_window() const, gtk_viewport_get_bin_window, refreturn, constversion) |
| 53 |
|
| 54 |
_WRAP_METHOD(Glib::RefPtr<Gdk::Window> get_view_window(), gtk_viewport_get_view_window, refreturn) |
| 55 |
_WRAP_METHOD(Glib::RefPtr<const Gdk::Window> get_view_window() const, gtk_viewport_get_view_window, refreturn, constversion) |
| 56 |
|
| 57 |
_WRAP_PROPERTY("shadow_type", ShadowType) |
| 58 |
}; |
| 59 |
|
| 60 |
} //namespace Gtk |