/*  Inti: Integrated Foundation Classes
 *  Copyright (C) 2002-2003 The Inti Development Team.
 *  Copyright (C) 2000 Red Hat, Inc.
 *
 *  This program is free software; you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation; either version 2 of the License, or
 *  (at your option) any later version.
 *
 *  This program is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU Library General Public License for more details.
 *
 *  You should have received a copy of the GNU Library General Public License
 *  along with this program; if not, write to the Free Software
 *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
 */

//! @file inti/gtk/widget.h
//! @brief A GtkWidget C++ wrapper interface.
//! 
//! Provides Widget, the base class for widgets that make up the GTK+ graphical user interface,
//! such as windows, menus, buttons, scrollbars editors, drawing areas, and so on. 

#ifndef INTI_GTK_WIDGET_H
#define INTI_GTK_WIDGET_H

#ifndef INTI_GTK_OBJECT_H
#include <inti/gtk/object.h>
#endif

#ifndef INTI_ATK_IMPLEMENTOR_H
#include <inti/atk/implementor.h>
#endif

#ifndef INTI_GTK_ADJUSTMENT_H
#include <inti/gtk/adjustment.h>
#endif

#ifndef INTI_GTK_ENUMS_H
#include <inti/gtk/enums.h>
#endif

#ifndef INTI_GDK_EVENTS_H
#include <inti/gdk/events.h>
#endif

#ifndef INTI_GTK_SELECTION_H
#include <inti/gtk/selection.h>
#endif

namespace Inti {

namespace Atk {
class Object;
}

namespace Gdk {
class Bitmap;
class Color;
class Colormap;
class Cursor;
class Display;
class Event;
class Pixbuf;
class Region;
class Screen;
class Visual;
class Window;
}

namespace G {
class Value;
}

namespace Pango {
class Context;
class FontDescription;
class Layout;
}

namespace Gtk {

class AccelGroup;
class AccelKey;
class Clipboard;
class Container;
class RcStyle;
class Selection;
class Settings;
class Style;
class WidgetClass;

//! @enum WidgetFlags
//! WidgetFlags tells about certain properties of the widget. 

enum WidgetFlags
{
	TOP_LEVEL = GTK_TOPLEVEL,
	//!< Widgets without a real parent, such as Windows and Menus have this flag
	//!< set throughout their lifetime; Toplevel widgets always contain their own
	//!< Gdk::Window.
	
	NO_WINDOW = GTK_NO_WINDOW,
	//!< Indicative for a widget that does not provide its own Gdk::Window;
	//!< For such widgets, visible actions (such as drawing) are performed
	//!< on the parent's Gdk::Window.
	
	REALIZED = GTK_REALIZED,
	//!< Set by realize(), unset by unrealize(); A realized widget has an associated Gdk::Window.
	
	MAPPED = GTK_MAPPED,
	//!< Set by map(), unset by unmap(); Only realized widgets can be mapped;
	//!< It means that show() has been called on the widgets window(s).
	
	VISIBLE = GTK_VISIBLE,
	//!< Set by show(), unset by hide(); Implies that a widget will be mapped
	//!< as soon as its parent is mapped. 
	
	SENSITIVE = GTK_SENSITIVE,
	//!< Set and unset by set_sensitive(); The sensitivity of a widget determines
	//!< whether it will receive certain events (such as button or key presses);
	//!< One premise for the widget's sensitivity is to have this flag set.
	
	PARENT_SENSITIVE = GTK_PARENT_SENSITIVE,
	//!< Set and unset by set_sensitive() operations on the parents of the widget;
	//!< This is the second premise for the widget's sensitivity; Once it has
	//!< SENSITIVE and PARENT_SENSITIVE set, its state is effectively sensitive
	//!< and Gtk::Widget::is_sensitive() will return true.

	CAN_FOCUS = GTK_CAN_FOCUS,
	//!< Determines whether a widget is able to handle focus grabs.

	HAS_FOCUS = GTK_HAS_FOCUS,
	//!< Set by grab_focus() for widgets that also have CAN_FOCUS set; This flag
	//!< will be unset once another widget grabs the focus. 
	
	CAN_DEFAULT = GTK_CAN_DEFAULT,
	//!< The widget is allowed to receive the default action via grab_default(). 
	
	HAS_DEFAULT = GTK_HAS_DEFAULT,
	//!< The widget currently is receiving the default action. 
	
	HAS_GRAB = GTK_HAS_GRAB,
	//!< Set by gtk_grab_add(), unset by gtk_grab_remove(); It means that the widget
	//!< is in the grab_widgets stack, and will be the preferred one for receiving
	//!< events other than ones of cosmetic value. 
	
	RC_STYLE = GTK_RC_STYLE,
	//!< Indicates that the widgets style has been looked up through the rc mechanism; It does
	//!< not imply that the widget actually had a style defined through the rc mechanism. 
	
	COMPOSITE_CHILD = GTK_COMPOSITE_CHILD,
	//!< Indicates that the widget is a composite child of its parent; 
	//!< see push_composite_child(), pop_composite_child(). 
	
	NO_REPARENT = GTK_NO_REPARENT,
	//!< Unused since before GTK+ 1.2, will be removed in a future version. 
	
	APP_PAINTABLE = GTK_APP_PAINTABLE,
	//!< Set and unset by set_app_paintable(); Must be set on widgets whose window the application
	//!< directly draws on, in order to keep GTK+ from overwriting the drawn stuff. 
	
	RECEIVES_DEFAULT = GTK_RECEIVES_DEFAULT,
	//!< The widget when focused will receive the default action and have HAS_DEFAULT
	//!< set even if there is a different widget set as default.
	
	DOUBLE_BUFFERED = GTK_DOUBLE_BUFFERED
	//!< Set and unset by set_double_buffered(); Indicates that exposes
	//!< done on the widget should be double-buffered.
};

//! WidgetFlagsField holds one or more values from the WidgetFlags enumeration OR'd together.

typedef unsigned int WidgetFlagsField;

//! @enum WidgetHelpType
//! WidgetHelpType defines the type of help, either tooltip or "What's this".

enum WidgetHelpType
{
	WIDGET_HELP_TOOLTIP = GTK_WIDGET_HELP_TOOLTIP, //!< Tooltip help.
	WIDGET_HELP_WHATS_THIS = GTK_WIDGET_HELP_WHATS_THIS //!< "What's this" help.
};

//! @class Allocation widget.h inti/gtk/widget.h
//! @brief A GtkAllocation C++ wrapper class.
//!
//! Allocation holds the position and size allocated to a widget. It derives publicly
//! from Gdk::Rectangle, which derives publicly from GdkRectangle. Allocation uses 
//! default copy, assignment and destruction and allows public access to GdkRectangle's 
//! x, y, width and height fields.

class Allocation : public Gdk::Rectangle
{
public:
//! @name Constructors
//! @{

	Allocation();
	//!< Construct an empty allocation.

	Allocation(int x, int y, int width, int height);
	//!< Construct an allocation with the specified position an size.
	//!< @param x The X coordinate.
	//!< @param y The Y coordinate.
	//!< @param width The width of the allocation.
	//!< @param height The height of the allocation.
	
//! @}
//! @name Accessors
//! @{

	GtkAllocation* gtk_allocation() const { return (GtkAllocation*)this; }
	//!< Get a pointer to the GtkAllocation structure (GtkAllocation is a 
	//!< typedef for GdkRectangle).
	
//! @}
};

//! @class Requisition widget.h inti/gtk/widget.h
//! @brief A GtkRequisition C++ wrapper class.
//!
//! Requisition holds the preferred size for a widget. It derives publicly from
//! GtkRequisition. Requisition uses default copy, assignment and destruction
//! and allows public access to GtkRequisition's width and height fields.

class Requisition
{
	GtkRequisition requisition_;

public:
//! @name Constructors
//! @{

	Requisition();
	//!< Construct an empty requisition.

	Requisition(int width, int height);
	//!< Construct a requisition with the specified width and height.
	//!< @param width The width of the requisition.
	//!< @param height The height of the requisition.

	Requisition(const GtkRequisition& requisition);
	//!< Construct a requisition from an exisiting GtkRequisition.
	//!< @param requisition A GtkRequisition.

//! @}
//! @name Accessors
//! @{

	GtkRequisition* gtk_requisition() const { return const_cast<GtkRequisition*>(&requisition_); }
	//!< Get a pointer to the GtkRequisition structure.

	operator GtkRequisition* () const;
	//!< Conversion operator; safely converts a Requisition to a GtkRequisition pointer.

	int width() const;
	//!< Returns the requisition width.

	int height() const;
	//!< Returns the requisition height.

	bool operator==(const Requisition& other) const;
	//!< Returns <EM>true</EM> if this requisition is equal to <EM>other</EM>.
	//!< @param other Another Requisition. 

	bool operator!=(const Requisition& other) const;
	//!< Returns <EM>true</EM> if this requisition is not equal to <EM>other</EM>. 
	//!< @param other Another Requisition. 

//! @}
//! @name Methods
//! @{

	void set(int width, int height);
	//!< Set the width and height for the requisition.
	//!< @param width The new width of the requisition.
	//!< @param height The new height of the requisition.
	
//! @}
};

//! @class Widget widget.h inti/gtk/widget.h
//! @brief A GtkWidget C++ wrapper class.
//!
//! Widget is the base class for widgets that make up the graphical user interface,
//! such as windows, menus, buttons, scrollbars, editors, drawing areas, and so on.
//!
//! After implementing a widget in your application you frequently need to set some
//! widget-specific attributes, such as the widget's size, position, and so on.
//! When the user interacts with a widget, such as pulling down a menu and making
//! a selection, clicking a button, or moving a scrollbar, your application needs to
//! respond by calling a callback slot that you supply. Callback slots are objects 
//! that call the class or static method that you want attached to a user action.
//! 
//! A parent-child relationship must be established between widgets in your application,
//! such as by packing a button into a box or adding a menu item to a menu. These 
//! releationships provide management capabitilies and help determine the layout
//! of the user interface. After widgets are created, parent-child relationships
//! established, and callback slots attached you need to display the widgets. This is
//! accomplished by calling show() on a widget, or show_all() on the parent widget to
//! to show all the child widgets at once.
//!
//! Any user action in you interface causes the corresponding widget to emit a signal,
//! to which your callback slot has been attached. You can respond to these signals
//! in two ways. The first way is to derive a new class from the widget, such as 
//! Gtk::Button, and override one or more of its inherited virutal signal handlers,
//! such as on_clicked() for the button's "clicked" signal. Continuing with 
//! Gtk::Button, the second way is to create an instance of Gtk::Button and attach to
//! it your clicked callback slot, by calling sig_clicked().connect(slot());
//!
//! Widget implements this Atk::Implementor interface. Calling get_accessible() is the
//! same as calling ref_accessible() inherited from Atk::Implementor, except 
//! ref_accessible() returns a smart pointer.

class Widget : public Object, public Atk::Implementor
{
	friend class G::Object;
	friend class WidgetClass;

	Widget(const Widget&);
	Widget& operator=(const Widget&);

protected:
//! @name Constructors
//! @{

	Widget();
	//!< Construct a new widget.

	explicit Widget(GtkWidget *widget, bool reference = false);
	//!< Construct a new Widget from an existing GtkWidget.
	//!< @param widget A pointer to a GtkWidget.
	//!< @param reference Set false if the initial reference count is floating, set true if it's not.
	//!<
	//!< <BR>The <EM>widget</EM> can be a newly created GtkWidget or an existing
	//!< GtkWidget (see G::Object::Object).

//! @}
//! @name Methods
//! @{

	virtual void initialize();
	//!< Called implicitly immediately after the widget is realized but before it is mapped 
	//!< (becomes visible on the screen). This is useful for initializing data common to
	//!< several constructors or for implementing code that requires the widget to have been 
	//!< realized first.
	
	void set_allocation(const Allocation& allocation);
	//!< Sets the position and size allocated to a child widget.
	//!< @param allocation The position and size to be allocated to the widget.
	//!<
	//!< <BR>This method can be called from the widget's virtual <EM>on_size_request</EM>
	//!< to set the allocation (see the Dial example program).

	void set_window(const Gdk::Window& window);
	//!< Sets the Gdk::Window for the widget.
	//!< @param window A Gdk::Window.
	//!<
	//!< <BR>This method only works if gtk_widget()->window is null. It is only for use when
	//!< implementing a custom widget that derives directly from Gtk::Widget. After creating
	//!< a Gdk::Window for the custom widget in the widget's virtual <EM>on_realize()</EM>
	//!< method you should call this method to set the window. If the widget already has a
	//!< Gdk::Window nothing happens (see the Dial example program).

//! @}
//  Override these do_ methods when you want to change the default behaviour of the GtkWidget.

	virtual void do_dispatch_child_properties_changed(unsigned int n_pspecs, GParamSpec **pspecs);

	virtual void do_show_all();

	virtual void do_hide_all();

	virtual AtkObject* do_get_accessible();

//! @name Basic Signal Handlers
//! @{

	virtual void on_show();
	//!< Called when a widget becomes visible.

	virtual void on_hide();
	//!< Called when a widget is hidden (invisible to the user).

	virtual void on_map();
	//!< Called when a widget becomes mapped.

	virtual void on_unmap();
	//!< Called when a widget becomes unmapped.

	virtual void on_realize();
	//!< Called when a widget is realized.

	virtual void on_unrealize();
	//!< Called when a widget is unrealized.

	virtual void on_size_request(Requisition *requisition);
	//!< Called to obtain the preferred size of a widget.
	//!< @param requisition The Requisition to be filled in.

	virtual void on_size_allocate(const Allocation& allocation);
	//!< Called when a child widget is allocated a size and position.
	//!< @param allocation The position and size allocated to the widget. 

	virtual void on_state_changed(StateType previous_state);
	//!< Called when the widget state changes.
	//!< @param previous_state The previous StateType.

	virtual void on_parent_set(Widget *previous_parent);
	//!< Called when the parent container of the widget is set.
	//!< @param previous_parent The previous parent of the widget, or null.

	virtual void on_hierarchy_changed(Widget *previous_toplevel);
	//!< Called when there is a change in the hierarchy to which the widget belongs. 
	//!< @param previous_toplevel The previous toplevel widget.
	//!<
	//!< <BR>More precisely, a widget is anchored when its toplevel ancestor is a Gtk::Window.
	//!< This handler is called when a widget changes from un-anchored to anchored or vice-versa. 
		
	virtual void on_style_set(Style* previous_style);
	//!< Called when the widget style is changed.
	//!< @param previous_style The previous Style, or null.

	virtual void on_direction_changed(TextDirection  previous_direction);
	//!< Called when the reading direction on the widget is changed.
	//!< @param previous_direction The previous direction.

	virtual void on_grab_notify(bool was_grabbed);
	//!< Called to notify the widget whether it is the current grabbed widget in an application.
	//!< @param was_grabbed <EM>true</EM> if the widget is the current grabbed widget, <EM>false</EM>
	//!<                    if it was but is no longer the current grabbed widget.
	//!<
	//!< <BR>The grabbed widget within an application is the widget that recieves all mouse
	//!< and keyboard events, while interaction with other widgets is blocked.  

	virtual void on_child_notify(GParamSpec *pspec);
	//!< Called when a child widget property is changed.
	//!< @param pspec A GParamSpec object that holds the meta data specifying the new property.

	virtual bool on_mnemonic_activate(bool group_cycling);
	//!< Called to activate the widget when the mnemonic key it's associated with is pressed.
	//!< @param group_cycling

	virtual void on_grab_focus();
	//!< Called when the widget receives the keyboard focus for the Window it's inside. 	

	virtual bool on_focus(DirectionType direction);
	//!< Called when a child widget receives the focus (see child_focus()).
	//!< @param direction The direction of focus movement. 
	//!< @return <EM>true</EM> if the focus ended up inside the child widget.

	virtual void on_screen_changed(Gdk::Screen *previous_screen);
	//!< Called when the screen the widget is displayed on is changed.
	//!< @param previous_screen The previous Gdk:Screen.

//! @}
//! @name Selection Signal Handlers
//! @{

	virtual void on_selection_get(SelectionData& selection_data, unsigned int info, unsigned int time);
	//!< Called when the selection data is requested, if this widget is the selection owner.
	//!< @param selection_data The SelectionData object to be filled in.
	//!< @param info The info integer that was set when the target was registered (see TargetEntry).
	//!< @param time The time of the conversion request as set by the requestor with selectionn_convert().
	//!<
	//!< <BR>This handler is called in response to a call to <EM>selection_convert()</EM> 
	//!< by the selection requestor. The <EM>selection_data</EM> object needs to be filled 
	//!< in. Calling Gtk::SelectionData::get_target() and Gtk::SelectionData::get_selection()
	//!< enables you to know for which target of which selection the data needs to be
	//!< formatted. The formatted data can then be set by calling Gtk::SelectionData:set() 
	//!< or Gtk::SelectionData::set_text(). The selection requestor will receive the data
	//!< when this handler returns.
	
	virtual void on_selection_received(const SelectionData& selection_data, unsigned int time);
	//!< Called to notify the widget that the requested selection data has been
	//!< converted and provided by the selection owner.
	//!< @param selection_data The requested selection data.
	//!< @param time The time of the conversion request.
		
//! @}
//! @name Source-side Drag Signal Handlers
//! @{

	virtual void on_drag_begin(DragContext& context);
	//!< Called to notify the widget that a drag-and-drop event has started.
	//!< @param context A reference to a Gtk::DragContext (only used by GTK+).
	//!<
	//!< <BR>It's quite useful to know when a drag-and-drop event has started. This makes it
	//!< possible to create a snapshot of the data that will be provided for each target and
	//!< to make sure that each event contains the latest version of the data.

	virtual void on_drag_end(DragContext& context);
	//!< Called to notify the widget that a drag-and-drop event has ended.
	//!< @param context A reference to a Gtk::DragContext (only used by GTK+).
	//!<
	//!< <BR>It's useful to be notified when a drag-and-drop event ends. This allows
	//!< you to free memory that was allocated when the event was started.

	virtual void on_drag_data_get(DragContext& context, SelectionData& data, unsigned int info, unsigned int time);
	//!< Called after a valid drop to request the data of the first target
	//!< supported by the destination widget.
	//!< @param context A reference to a Gtk::DragContext (only used by GTK+).
	//!< @param data The SelectionData that needs to be filled in to provide the requested data.
	//!< @param info The info integer that was set when the target was registered (see TargertEntry).
	//!< @param time The time of the conversion request.
	//!< 
	//!< <BR>To provide the data for the requested target <EM>data</EM> needs to be filled in.
	//!< Calling Gtk::SelectionData::get_target() enables you to know for which target the
	//!< data needs to be formatted. The formatted data can then be set by calling
	//!< Gtk::SelectionData:set() or Gtk::SelectionData::set_text(). The destination widget
	//!< will receive the data when this handler returns.
		
	virtual void on_drag_data_delete(DragContext& context);
	//!< Called after a successful drop to indicate that the data can be deleted.
	//!< @param context A reference to a Gtk::DragContext (only used by GTK+).
	//!<
	//!< <BR>The <EM>drag_data_delete</EM> signal is used internally by GTK+ to 
	//!< implement drag-and-drop support in text widgets, such as entry, TextBuffer
	//!< and TextView. It wont be of much use to you unless you're implementing
	//!< manual drag-and-drop.
	
//! @}
//! @name Target-side Drag Signal Handlers
//! @{

	virtual void on_drag_leave(DragContext& context, unsigned int time);
	//!< Called whenever a drag-and-drop action leaves the widget.
	//!< @param context A reference to the Gtk::DragContext for the current drag-and-drop event.
	//!< @param time The time when the event occurred.
	//!<
	//!< <BR>This handler might be useful to undo any action you took when the widget 
	//!< was first entered (i.e. on the first <EM>drag_motion</EM> signal). 
	
	virtual bool on_drag_motion(DragContext& context, int x, int y, unsigned int time);
	//!< Called when the mouse passes over the widget to verifiy whether it can accept a drop.
	//!< @param context A reference to the Gtk::DragContext for the current drag-and-drop event.
	//!< @param x The X position of the mouse pointer relative to the widget. 
	//!< @param y The Y position of the mouse pointer relative to the widget. 
	//!< @param time The time when the event occurred.
	//!< @return <EM>true</EM> if the widget is a valid drag-and-drop destination.
	//!<
	//!< <BR>If false is returned the widget is not a drag-and-drop destination and
	//!< the parent should be checked instead. When true is returned, the widget 
	//!< will be seen as a drag-and-drop destination and you'll have to verify if
	//!< it can accept a drop. 
	//!<
	//!< Gdk::DragContext::targets() retrieves a list of atoms of all the targets
	//!< supported by the source widget. You need this list to verify if one of the
	//!< targets corresponds to the targets that can be accepted by the destination
	//!< widget. Gdk::DragContext::actions() returns the actions supported by the
	//!< source widget. Gdk::DragContext::suggested_action() returns the action 
	//!< suggested by automatically by GTK+. You're free to choose any of the
	//!< default actions but this action is usually the best choice.
	//!<
	//!< The source widget needs to be notified if the destination widget will accept
	//!< a drop according to the provided targets and actions. This is done by calling 
	//!< Gdk::DragContext::status(). This method must always be called if this handler
	//!< returns true. If it's not called the source widget will not issue another
	//!< <EM>drag_motion</EM> signal.
	
	virtual bool on_drag_drop(DragContext& context, int x, int y, unsigned int time);
	//!< Called to notify the widget that a drop has occurred.
	//!< @param context A reference to the Gtk::DragContext for the current drag-and-drop event.
	//!< @param x The X position of the mouse pointer relative to the widget. 
	//!< @param y The Y position of the mouse pointer relative to the widget. 
	//!< @param time The time when the event occurred.
	//!< @return <EM>true</EM> if the widget is a valid drag-and-drop destination.
	//!<
	//!< <BR>Gdk::DragContext::targets() can be called to decide which target's data
	//!< has to be obtained. When this is known, the drag_get_data() method has to
	//!< be called to actually request the data. The data will be provided through
	//!< a <EM>drag_data_received</EM> signal.

	virtual void on_drag_data_received(DragContext& context, int x, int y, const SelectionData& data, unsigned int info, unsigned int time);
	//!< Called to notify the widget when the data from a drop is received.
	//!< @param context A reference to a Gtk::DragContext.
	//!< @param x The X position of the mouse pointer relative to the widget. 
	//!< @param y The Y position of the mouse pointer relative to the widget. 
	//!< @param data The SelectionData that contains all the information about the data received.
	//!< @param info The info integer that was set when the target was registered (see TargertEntry).
	//!< @param time The time of the conversion request.
	
//! @}
//! @name GDK Event Signal Handlers
//! @{

	virtual bool on_event(const Gdk::Event& event);
	//!< Called when any GDK event occurs.
	//!< @param event The Gdk::Event.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_button_press_event(const Gdk::EventButton& event);
	//!< Called when a mouse button has been pressed.
	//!< @param event The Gdk::EventButton.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_button_release_event(const Gdk::EventButton& event);
	//!< Called when a mouse button has been released.
	//!< @param event The Gdk::EventButton.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_scroll_event(const Gdk::EventScroll& event);
	//!< Called when a mouse wheel is scrolled either up or down.
	//!< @param event The Gdk::EventScroll.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_motion_notify_event(const Gdk::EventMotion& event);
	//!< Called when the mouse is moved.
	//!< @param event The Gdk::EventMotion.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_destroy_event(const Gdk::EventAny& event);
	//!< Called when the widget has been destroyed.
	//!< @param event The Gdk::EventAny.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_expose_event(const Gdk::EventExpose& event);
	//!< Called when all or part of the widget has become visible and needs to be redrawn.
	//!< @param event The Gdk::EventExpose.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_key_press_event(const Gdk::EventKey& event);
	//!< Called when a key is pressed.
	//!< @param event The Gdk::EventKey.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_key_release_event(const Gdk::EventKey& event);
	//!< Called when a key is released.
	//!< @param event The Gdk::EventKey.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_enter_notify_event(const Gdk::EventCrossing& event);
	//!< Called when a widget is entered.
	//!< @param event The Gdk::EventCrossing.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_leave_notify_event(const Gdk::EventCrossing& event);
	//!< Called when a widget is exited.
	//!< @param event The Gdk::EventCrossing.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_configure_event(const Gdk::EventConfigure& event);
	//!< Called when the size, position or stacking order of the widget is changed.
	//!< @param event The Gdk::EventConfigure.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.
	//!<
	//!< <BR>Note that these events are discarded for Gdk::WINDOW_CHILD windows.

	virtual bool on_focus_in_event(const Gdk::EventFocus& event);
	//!< Called when the widget gains the keybaord focus (the focus widget gets keyboard events).
	//!< @param event The Gdk::EventFocus.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_focus_out_event(const Gdk::EventFocus& event);
	//!< Called when the widget looses the keyboard focus.
	//!< @param event The Gdk::EventFocus.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_map_event(const Gdk::EventAny& event);
	//!< Called when the widget has been mapped (visible on the screen).
	//!< @param event The Gdk::EventAny.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_unmap_event(const Gdk::EventAny& event);
	//!< Called when the widget has been unmapped (no longer visible on the screen).
	//!< @param event The Gdk::EventAny.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_property_notify_event(const Gdk::EventProperty& event);
	//!< Called when a property on the widget has been changed or deleted.
	//!< @param event The Gdk::EventProperty.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_selection_clear_event(const Gdk::EventSelection& event);
	//!< Called when an application has lost ownership of a selection.
	//!< @param event The Gdk::EventSelection.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_selection_request_event(const Gdk::EventSelection& event);
	//!< Called when another application has requested a selection.
	//!< @param event The Gdk::EventSelection.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_selection_notify_event(const Gdk::EventSelection& event);
	//!< Called when a selection has been received.
	//!< @param event The Gdk::EventSelection.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_proximity_in_event(const Gdk::EventProximity& event);
	//!< Called when an input device has moved into contact with a sensing surface
	//!< (such as a touchscreen or graphics tablet).
	//!< @param event The Gdk::EventProximity.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_proximity_out_event(const Gdk::EventProximity& event);
	//!< Called when an input device has moved out of contact with a sensing surface.
	//!< @param event The Gdk::EventProximity.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_visibility_notify_event(const Gdk::EventVisibility& event);
	//!< Called when the widget's visibility status has changed (either fully obscured,
	//!< partially obscured or unobscured.
	//!< @param event The Gdk::EventVisibility.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_client_event(const Gdk::EventClient& event);
	//!< Called when a message has been received from another application.
	//!< @param event The Gdk::EventClient.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

	virtual bool on_no_expose_event(const Gdk::EventAny& event);
	//!< Called when all or part of the widget has become visible, but no expose event was generated.
	//!< @param event The Gdk::EventAny.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.
	//!<
	//!< <BR>Indicates that the source region was completely available when parts of a drawable
	//!< were copied. This is not very useful.

	virtual bool on_window_state_event(const Gdk::EventWindowState& event);
	//!< Called when the state of a toplevel window changes (either not shown, minimized,
	//!< maximized, sticky or fullscreen).
	//!< @param event The Gdk::EventWindowState.
	//!< @return <EM>true</EM> to stop invoking other handlers, <EM>false</EM> to propagate the event.

//! @}
//  Properties

	typedef G::Property<String> NamePropertyType;
	typedef G::PropertyProxy<G::Object, NamePropertyType> NamePropertyProxy;
	static const NamePropertyType name_property;

	typedef G::Property<Container*, G::Object*> ParentPropertyType;
	typedef G::PropertyProxy<G::Object, ParentPropertyType> ParentPropertyProxy;
	static const ParentPropertyType parent_property;

	typedef G::Property<int> WidthRequestPropertyType;
	typedef G::PropertyProxy<G::Object, WidthRequestPropertyType> WidthRequestPropertyProxy;
	static const WidthRequestPropertyType width_request_property;

	typedef G::Property<int> HeightRequestPropertyType;
	typedef G::PropertyProxy<G::Object, HeightRequestPropertyType> HeightRequestPropertyProxy;
	static const HeightRequestPropertyType height_request_property;

	typedef G::Property<bool> VisiblePropertyType;
	typedef G::PropertyProxy<G::Object, VisiblePropertyType> VisiblePropertyProxy;
	static const VisiblePropertyType visible_property;

	typedef G::Property<bool> SensitivePropertyType;
	typedef G::PropertyProxy<G::Object, SensitivePropertyType> SensitivePropertyProxy;
	static const SensitivePropertyType sensitive_property;

	typedef G::Property<bool> AppPaintablePropertyType;
	typedef G::PropertyProxy<G::Object, AppPaintablePropertyType> AppPaintablePropertyProxy;
	static const AppPaintablePropertyType app_paintable_property;

	typedef G::Property<bool> CanFocusPropertyType;
	typedef G::PropertyProxy<G::Object, CanFocusPropertyType> CanFocusPropertyProxy;
	static const CanFocusPropertyType can_focus_property;

	typedef G::Property<bool> HasFocusPropertyType;
	typedef G::PropertyProxy<G::Object, HasFocusPropertyType> HasFocusPropertyProxy;
	static const HasFocusPropertyType has_focus_property;

	typedef G::Property<bool> IsFocusPropertyType;
	typedef G::PropertyProxy<G::Object, IsFocusPropertyType> IsFocusPropertyProxy;
	static const IsFocusPropertyType is_focus_property;
	
	typedef G::Property<bool> CanDefaultPropertyType;
	typedef G::PropertyProxy<G::Object, CanDefaultPropertyType> CanDefaultPropertyProxy;
	static const CanDefaultPropertyType can_default_property;

	typedef G::Property<bool> HasDefaultPropertyType;
	typedef G::PropertyProxy<G::Object, HasDefaultPropertyType> HasDefaultPropertyProxy;
	static const HasDefaultPropertyType has_default_property;

	typedef G::Property<bool> ReceivesDefaultPropertyType;
	typedef G::PropertyProxy<G::Object, ReceivesDefaultPropertyType> ReceivesDefaultPropertyProxy;
	static const ReceivesDefaultPropertyType receives_default_property;

	typedef G::Property<bool> CompositeChildPropertyType;
	typedef G::PropertyProxy<G::Object, CompositeChildPropertyType> CompositeChildPropertyProxy;
	static const CompositeChildPropertyType composite_child_property;

	typedef G::Property<Style*, G::Object*> StylePropertyType;
	typedef G::PropertyProxy<G::Object, StylePropertyType> StylePropertyProxy;
	static const StylePropertyType style_property;

	typedef G::Property<Gdk::EventMask, unsigned int> EventsPropertyType;
	typedef G::PropertyProxy<G::Object, EventsPropertyType> EventsPropertyProxy;
	static const EventsPropertyType events_property;

	typedef G::Property<Gdk::ExtensionMode, int> ExtensionEventsPropertyType;
	typedef G::PropertyProxy<G::Object, ExtensionEventsPropertyType> ExtensionEventsPropertyProxy;
	static const ExtensionEventsPropertyType extension_events_property;

//  Basic Signals

	typedef G::Signal0<void> ShowSignalType;
	typedef G::SignalProxy<TypeInstance, ShowSignalType> ShowSignalProxy;
	static const ShowSignalType show_signal;

	typedef G::Signal0<void> HideSignalType;
	typedef G::SignalProxy<TypeInstance, HideSignalType> HideSignalProxy;
	static const HideSignalType hide_signal;

	typedef G::Signal0<void> MapSignalType;
	typedef G::SignalProxy<TypeInstance, MapSignalType> MapSignalProxy;
	static const MapSignalType map_signal;

	typedef G::Signal0<void> UnmapSignalType;
	typedef G::SignalProxy<TypeInstance, UnmapSignalType> UnmapSignalProxy;
	static const UnmapSignalType unmap_signal;

	typedef G::Signal0<void> RealizeSignalType;
	typedef G::SignalProxy<TypeInstance, RealizeSignalType> RealizeSignalProxy;
	static const RealizeSignalType realize_signal;

	typedef G::Signal0<void> UnrealizeSignalType;
	typedef G::SignalProxy<TypeInstance, UnrealizeSignalType> UnrealizeSignalProxy;
	static const UnrealizeSignalType unrealize_signal;

	typedef G::Signal1<void, GtkRequisition*> SizeRequestSignalType;
	typedef G::SignalProxy<TypeInstance, SizeRequestSignalType> SizeRequestSignalProxy;
	static const SizeRequestSignalType size_request_signal;

	typedef G::Signal1<void, GtkAllocation*> SizeAllocateSignalType;
	typedef G::SignalProxy<TypeInstance, SizeAllocateSignalType> SizeAllocateSignalProxy;
	static const SizeAllocateSignalType size_allocate_signal;

	typedef G::Signal1<void, GtkStateType> StateChangedSignalType;
	typedef G::SignalProxy<TypeInstance, StateChangedSignalType> StateChangedSignalProxy;
	static const StateChangedSignalType state_changed_signal;

	typedef G::Signal1<void, GtkWidget*> ParentSetSignalType;
	typedef G::SignalProxy<TypeInstance, ParentSetSignalType> ParentSetSignalProxy;
	static const ParentSetSignalType parent_set_signal;

	typedef G::Signal1<void, GtkWidget*> HierarchyChangedSignalType;
	typedef G::SignalProxy<TypeInstance, HierarchyChangedSignalType> HierarchyChangedSignalProxy;
	static const HierarchyChangedSignalType hierarchy_changed_signal;

	typedef G::Signal1<void, GtkStyle*> StyleSetSignalType;
	typedef G::SignalProxy<TypeInstance, StyleSetSignalType> StyleSetSignalProxy;
	static const StyleSetSignalType style_set_signal;

	typedef G::Signal1<void, GtkTextDirection> DirectionChangedSignalType;
	typedef G::SignalProxy<TypeInstance, DirectionChangedSignalType> DirectionChangedSignalProxy;
	static const DirectionChangedSignalType direction_changed_signal;

	typedef G::Signal1<void, bool> GrabNotifySignalType;
	typedef G::SignalProxy<TypeInstance, GrabNotifySignalType> GrabNotifySignalProxy;
	static const GrabNotifySignalType grab_notify_signal;

	typedef G::Signal1<void, GParamSpec*> ChildNotifySignalType;
	typedef G::SignalProxy<TypeInstance, ChildNotifySignalType> ChildNotifySignalProxy;
	static const ChildNotifySignalType child_notify_signal;

	typedef G::Signal1<bool, bool> MnemonicActivateSignalType;
	typedef G::SignalProxy<TypeInstance, MnemonicActivateSignalType> MnemonicActivateSignalProxy;
	static const MnemonicActivateSignalType mnemonic_activate_signal;

	typedef G::Signal0<void> GrabFocusSignalType;
	typedef G::SignalProxy<TypeInstance, GrabFocusSignalType> GrabFocusSignalProxy;
	static const GrabFocusSignalType grab_focus_signal;

	typedef G::Signal1<bool, GtkDirectionType> FocusSignalType;
	typedef G::SignalProxy<TypeInstance, FocusSignalType> FocusSignalProxy;
	static const FocusSignalType focus_signal;

	typedef G::Signal1<void, GdkScreen*> ScreenChangedSignalType;
	typedef G::SignalProxy<TypeInstance, ScreenChangedSignalType> ScreenChangedSignalProxy;
	static const ScreenChangedSignalType screen_changed_signal;

//  Selection Signals

	typedef G::Signal3<void, GtkSelectionData*, unsigned int, unsigned int> SelectionGetSignalType;
	typedef G::SignalProxy<TypeInstance, SelectionGetSignalType> SelectionGetSignalProxy;
	static const SelectionGetSignalType selection_get_signal;

	typedef G::Signal2<void, GtkSelectionData*, unsigned int> SelectionReceivedSignalType;
	typedef G::SignalProxy<TypeInstance, SelectionReceivedSignalType> SelectionReceivedSignalProxy;
	static const SelectionReceivedSignalType selection_received_signal;

//  Source-side Drag Signals

	typedef G::Signal1<void, GdkDragContext*> DragBeginSignalType;
	typedef G::SignalProxy<TypeInstance, DragBeginSignalType> DragBeginSignalProxy;
	static const DragBeginSignalType drag_begin_signal;

	typedef G::Signal1<void, GdkDragContext*> DragEndSignalType;
	typedef G::SignalProxy<TypeInstance, DragEndSignalType> DragEndSignalProxy;
	static const DragEndSignalType drag_end_signal;

	typedef G::Signal4<void, GdkDragContext*, GtkSelectionData*, unsigned int, unsigned int> DragDataGetSignalType;
	typedef G::SignalProxy<TypeInstance, DragDataGetSignalType> DragDataGetSignalProxy;
	static const DragDataGetSignalType drag_data_get_signal;

	typedef G::Signal1<void, GdkDragContext*> DragDataDeleteSignalType;
	typedef G::SignalProxy<TypeInstance, DragDataDeleteSignalType> DragDataDeleteSignalProxy;
	static const DragDataDeleteSignalType drag_data_delete_signal;

//  Target-side Drag Signals

	typedef G::Signal2<void, GdkDragContext*, unsigned int> DragLeaveSignalType;
	typedef G::SignalProxy<TypeInstance, DragLeaveSignalType> DragLeaveSignalProxy;
	static const DragLeaveSignalType drag_leave_signal;

	typedef G::Signal4<bool, GdkDragContext*, int, int, unsigned int> DragMotionSignalType;
	typedef G::SignalProxy<TypeInstance, DragMotionSignalType> DragMotionSignalProxy;
	static const DragMotionSignalType drag_motion_signal;

	typedef G::Signal4<bool, GdkDragContext*, int, int, unsigned int> DragDropSignalType;
	typedef G::SignalProxy<TypeInstance, DragDropSignalType> DragDropSignalProxy;
	static const DragDropSignalType drag_drop_signal;

	typedef G::Signal6<void, GdkDragContext*, int, int, GtkSelectionData*, unsigned int, unsigned int> DragDataReceivedSignalType;
	typedef G::SignalProxy<TypeInstance, DragDataReceivedSignalType> DragDataReceivedSignalProxy;
	static const DragDataReceivedSignalType drag_data_received_signal;

//  GDK Event Signals

	typedef G::Signal1<bool, GdkEvent*> EventSignalType;
	typedef G::SignalProxy<TypeInstance, EventSignalType> EventSignalProxy;
	static const EventSignalType event_signal;

	typedef G::Signal1<bool, GdkEventButton*> ButtonPressEventSignalType;
	typedef G::SignalProxy<TypeInstance, ButtonPressEventSignalType> ButtonPressEventSignalProxy;
	static const ButtonPressEventSignalType button_press_event_signal;

	typedef G::Signal1<bool, GdkEventButton*> ButtonReleaseEventSignalType;
	typedef G::SignalProxy<TypeInstance, ButtonReleaseEventSignalType> ButtonReleaseEventSignalProxy;
	static const ButtonReleaseEventSignalType button_release_event_signal;

	typedef G::Signal1<bool, GdkEventScroll*> ScrollEventSignalType;
	typedef G::SignalProxy<TypeInstance, ScrollEventSignalType> ScrollEventSignalProxy;
	static const ScrollEventSignalType scroll_event_signal;

	typedef G::Signal1<bool, GdkEventMotion*> MotionNotifyEventSignalType;
	typedef G::SignalProxy<TypeInstance, MotionNotifyEventSignalType> MotionNotifyEventSignalProxy;
	static const MotionNotifyEventSignalType motion_notify_event_signal;

	typedef G::Signal1<bool, GdkEventAny*> DestroyEventSignalType;
	typedef G::SignalProxy<TypeInstance, DestroyEventSignalType> DestroyEventSignalProxy;
	static const DestroyEventSignalType destroy_event_signal;

	typedef G::Signal1<bool, GdkEventExpose*> ExposeEventSignalType;
	typedef G::SignalProxy<TypeInstance, ExposeEventSignalType> ExposeEventSignalProxy;
	static const ExposeEventSignalType expose_event_signal;

	typedef G::Signal1<bool, GdkEventKey*> KeyPressEventSignalType;
	typedef G::SignalProxy<TypeInstance, KeyPressEventSignalType> KeyPressEventSignalProxy;
	static const KeyPressEventSignalType key_press_event_signal;

	typedef G::Signal1<bool, GdkEventKey*> KeyReleaseEventSignalType;
	typedef G::SignalProxy<TypeInstance, KeyReleaseEventSignalType> KeyReleaseEventSignalProxy;
	static const KeyReleaseEventSignalType key_release_event_signal;

	typedef G::Signal1<bool, GdkEventCrossing*> EnterNotifyEventSignalType;
	typedef G::SignalProxy<TypeInstance, EnterNotifyEventSignalType> EnterNotifyEventSignalProxy;
	static const EnterNotifyEventSignalType enter_notify_event_signal;

	typedef G::Signal1<bool, GdkEventCrossing*> LeaveNotifyEventSignalType;
	typedef G::SignalProxy<TypeInstance, LeaveNotifyEventSignalType> LeaveNotifyEventSignalProxy;
	static const LeaveNotifyEventSignalType leave_notify_event_signal;

	typedef G::Signal1<bool, GdkEventConfigure*> ConfigureEventSignalType;
	typedef G::SignalProxy<TypeInstance, ConfigureEventSignalType> ConfigureEventSignalProxy;
	static const ConfigureEventSignalType configure_event_signal;

	typedef G::Signal1<bool, GdkEventFocus*> FocusInEventSignalType;
	typedef G::SignalProxy<TypeInstance, FocusInEventSignalType> FocusInEventSignalProxy;
	static const FocusInEventSignalType focus_in_event_signal;

	typedef G::Signal1<bool, GdkEventFocus*> FocusOutEventSignalType;
	typedef G::SignalProxy<TypeInstance, FocusOutEventSignalType> FocusOutEventSignalProxy;
	static const FocusOutEventSignalType focus_out_event_signal;

	typedef G::Signal1<bool, GdkEventAny*> MapEventSignalType;
	typedef G::SignalProxy<TypeInstance, MapEventSignalType> MapEventSignalProxy;
	static const MapEventSignalType map_event_signal;

	typedef G::Signal1<bool, GdkEventAny*> UnmapEventSignalType;
	typedef G::SignalProxy<TypeInstance, UnmapEventSignalType> UnmapEventSignalProxy;
	static const UnmapEventSignalType unmap_event_signal;

	typedef G::Signal1<bool, GdkEventProperty*> PropertyNotifyEventSignalType;
	typedef G::SignalProxy<TypeInstance, PropertyNotifyEventSignalType> PropertyNotifyEventSignalProxy;
	static const PropertyNotifyEventSignalType property_notify_event_signal;

	typedef G::Signal1<bool, GdkEventSelection*> SelectionClearEventSignalType;
	typedef G::SignalProxy<TypeInstance, SelectionClearEventSignalType> SelectionClearEventSignalProxy;
	static const SelectionClearEventSignalType selection_clear_event_signal;

	typedef G::Signal1<bool, GdkEventSelection*> SelectionRequestEventSignalType;
	typedef G::SignalProxy<TypeInstance, SelectionRequestEventSignalType> SelectionRequestEventSignalProxy;
	static const SelectionRequestEventSignalType selection_request_event_signal;

	typedef G::Signal1<bool, GdkEventSelection*> SelectionNotifyEventSignalType;
	typedef G::SignalProxy<TypeInstance, SelectionNotifyEventSignalType> SelectionNotifyEventSignalProxy;
	static const SelectionNotifyEventSignalType selection_notify_event_signal;

	typedef G::Signal1<bool, GdkEventProximity*> ProximityInEventSignalType;
	typedef G::SignalProxy<TypeInstance, ProximityInEventSignalType> ProximityInEventSignalProxy;
	static const ProximityInEventSignalType proximity_in_event_signal;

	typedef G::Signal1<bool, GdkEventProximity*> ProximityOutEventSignalType;
	typedef G::SignalProxy<TypeInstance, ProximityOutEventSignalType> ProximityOutEventSignalProxy;
	static const ProximityOutEventSignalType proximity_out_event_signal;

	typedef G::Signal1<bool, GdkEventVisibility*> VisibilityNotifyEventSignalType;
	typedef G::SignalProxy<TypeInstance, VisibilityNotifyEventSignalType> VisibilityNotifyEventSignalProxy;
	static const VisibilityNotifyEventSignalType visibility_notify_event_signal;

	typedef G::Signal1<bool, GdkEventClient*> ClientEventSignalType;
	typedef G::SignalProxy<TypeInstance, ClientEventSignalType> ClientEventSignalProxy;
	static const ClientEventSignalType client_event_signal;

	typedef G::Signal1<bool, GdkEventAny*> NoExposeEventSignalType;
	typedef G::SignalProxy<TypeInstance, NoExposeEventSignalType> NoExposeEventSignalProxy;
	static const NoExposeEventSignalType no_expose_event_signal;

	typedef G::Signal1<bool, GdkEventWindowState*> WindowStateEventSignalType;
	typedef G::SignalProxy<TypeInstance, WindowStateEventSignalType> WindowStateEventSignalProxy;
	static const WindowStateEventSignalType window_state_event_signal;

public:
//! @name Constructors
//! @{

	virtual ~Widget();
	//!< Destructor.

//! @}
//! @name Accessors
//! @{

	GtkWidget* gtk_widget() const { return (GtkWidget*)instance; }
	//!< Get a pointer to the GtkWidget structure.

	GtkWidgetClass* gtk_widget_class() const;
	//!< Get a pointer to the GtkWidgetClass structure.

	operator GtkWidget* () const;
	//!< Conversion operator; safely converts a Widget to a GtkWidget pointer.

	bool is_toplevel() const;
	//!< Returns true if the widget is a toplevel widget.

	bool has_no_window() const;
	//!< Returns true if the widget doesn't have it's own Gdk::Window.

	bool is_realized() const;
	//!< Returns true if the widget is realized.

	bool is_mapped() const;
	//!< Returns true if the widget is mapped.

	bool is_visible() const;
	//!< Returns true if the widget is visible.

	bool is_drawable() const;
	//!< Returns true if the widget is mapped and visible.

	bool sensitive() const;
	//!< Returns true if the Gtk::SENSITIVE flag has be set on the widget.

	bool parent_sensitive() const;
	//!< Returns true if the Gtk::PARENT_SENSITIVE flag has be set on the widget.

	bool is_sensitive() const;
	//!< Returns true if the widget is effectively sensitive.

	bool can_focus() const;
	//!< Returns true if the widget is able to handle focus grabs.

	bool has_focus() const;
	//!< Returns true if the widget has grabbed the focus and no other widget has done so more recently.

	bool can_default() const;
	//!< Returns true if the widget is allowed to receive the default action via grab_default().

	bool has_default() const;
	//!< Returns true if the widget currently is receiving the default action.
	
	bool has_grab() const;
	//!< Returns true if the widget is in the grab_widgets stack, and will be the preferred one
	//!< for receiving events other than ones of cosmetic value.

	bool has_rc_style() const;
	//!< Returns true if the widgets style has been looked up through the rc mechanism.

	bool is_composite_child() const;
	//!< Returns true if the widget is a composite child of its parent.

	bool is_app_paintable() const;
	//!< Returns true if the Gtk::APP_PAINTABLE flag has been set on the widget.

	bool receives_default() const;
	//!< Returns true if the widget when focused will receive the default action even if
	//!< there is a different widget set as default.

	bool is_double_buffered() const;
	//!< Returns true if the Gtk::DOUBLE_BUFFERED flag has been set on the widget.

	StateType get_state() const;
	//!< Returns the current state of the widget.

	const Allocation& get_allocation() const;
	//!< Returns the size allocated to the widget.

	Requisition get_child_requisition() const;
	//!< Obtains the child widget requisition (see get_child_requisition(Requisition&) const).
	//!< @return A Requisition that holds the child widget's width and height.
	
	void get_child_requisition(Requisition& requisition) const;
	//!< Obtains the child widget requisition, unless someone has forced a particular geometry on the widget, 
	//!< in which case it returns that geometry instead of the widget's requisition.
	//!< @param requisition The Requisition to be filled in.
	//!<
	//!< <BR>This method is only for use in widget implementations. It differs from size_request()
	//!< in that it retrieves the last size request value from gtk_widget()->requisition, while
	//!< size_request() actually calls the "size_request" method on the widget to compute the size
	//!< request and fill in gtk_widget()->requisition, and only then returns gtk_widget()->requisition.
	//!< Because this method does not call the "size_request" method, it can only be used when you
	//!< know that gtk_widget()->requisition is up-to-date, that is, size_request() has been called
	//!< since the last time a resize was queued. In general, only container implementations have
	//!< this information; applications should use size_request().
	
	Gdk::Window* get_window() const;
	//!< Returns the widget's window or its parent window if it doesn't have a window 
	//!< (which will be indicated by the Gtk::NO_WINDOW flag being set).

	bool is_focus() const;
	//!< Determines if the widget is the focus widget within its toplevel. 
	//!< @return <EM>true</EM> if the widget is the focus widget.
	//!<
	//!< <BR>This does not mean that the HAS_FOCUS flag is necessarily set; HAS_FOCUS will
	//!< only be set if the toplevel widget additionally has the global input focus.

	String get_name() const;
	//!< Retrieves the name of the widget (see set_name() for the significance of widget names).
	//!< @return The name of the widget.
	
	bool get_child_visible() const;
	//!< Returns the value set with set_child_visible(). 
	//!< @return <EM>true</EM> if the widget is mapped with the parent.
	//!<
	//!< <BR>If you feel a need to use this method, your code probably needs reorganization.
	//!< This method is only useful for container implementations and never should be called by an application.

	Widget* get_parent() const;
	//!< Returns the parent container of widget, or null.
	
	Gdk::Window* get_parent_window() const;
	//!< Returns the widget's parent window.
	
	void get_size_request(int *width, int *height) const;
	//!< Gets the size request that was explicitly set for the widget using set_size_request().
	//!< @param width The return location for the width, or null.
	//!< @param height The return location for the height, or null.
	//!<
	//!< <BR>A value of -1 stored in <EM>width</EM> or <EM>height</EM> indicates that that
	//!< dimension has not been set explicitly and the natural requisition of the widget
	//!< will be used intead. See set_size_request(). To get the size a widget will actually
	//!< use, call size_request() instead of this method.

	Gdk::ExtensionMode get_extension_events() const;
	//!< Retrieves the extension events the widget will receive (see Gdk::Input::set_extension_events()).
	
	Widget* get_toplevel() const;
	//!< This method returns the topmost widget in the container hierarchy the widget is a part of.
	//!< @return The topmost ancestor of widget, or widget itself if there's no ancestor.
	//!<
	//!< <BR>If widget has no parent widgets, it will be returned as the topmost widget. No reference
	//!< will be added to the returned widget; it should not be unreferenced. Note the difference in
	//!< behavior vs get_ancestor(); get_ancestor(Gtk::TYPE_WINDOW) would return null if widget wasn't
	//!< inside a toplevel window, and if the window was inside a Gtk::Window-derived widget which was
	//!< in turn inside the toplevel Gtk::Window. While the second case may seem unlikely, it actually
	//!< happens when a Plug is embedded inside a Socket within the same application.
	//!<
	//!< To reliably find the toplevel Gtk::Window, use get_toplevel() and check is_top_level() on the result.
	//!< @code
	//!< Gtk::Widget *toplevel = widget->get_toplevel();
	//!< if (is_toplevel())
	//!< {
	//!< 	// Perform action on toplevel.
	//!< }
	//!< @endcode

	Widget* get_ancestor(GType widget_type) const;
	//!< Gets the first ancestor of widget with type widget_type. 
	//!< @param widget_type The ancestor type.
	//!< @return The ancestor widget, or null if not found.
	//!<
	//!< <BR>For example, get_ancestor(GTK_TYPE_BOX) gets the first Box that's an ancestor of the widget.
	//!< No reference will be added to the returned widget; it should not be unreferenced. See note about
	//!< checking for a toplevel Gtk::Window in the docs for get_toplevel().

	Gdk::Colormap* get_colormap() const;
	//!< Returns the colormap that will be used to render the widget. No reference 
	//!< will be added to the returned colormap; it should not be unreferenced.
	
	const Gdk::Visual* get_visual() const;
	//!< Returns the visual that will be used to render widget.

	Gdk::Screen* get_screen() const;
	//!< Get the Gdk::Screen from the toplevel window associated with this widget.
	//!< @return The Gdk::Screen for the toplevel for this widget.
	//!<
	//!< <BR>This function can only be called after the widget has been added to a widget
	//!< hierarchy with a Gtk::Window at the top. In general, you should only create screen
	//!< specific resources when a widget has been realized, and you should free those
	//!< resources when the widget is unrealized.

	bool has_screen() const;
	//!< Checks whether there is a Gdk::Screen is associated with this widget.
	//!< @returns <EM>true</EM> if there is a Gdk::Screen associcated with the widget.
	//!<
	//!< <BR>All toplevel widgets have an associated screen, as do all widgets added into a
	//!< heirarchy with a toplevel window at the top.

	Gdk::Display* get_display() const;
	//!< Get the Gdk::Display for the toplevel window associated with this widget. 
	//!< @return The Gdk::Display for the toplevel for this widget.
	//!<
	//!< <BR>This method can only be called after the widget has been added to a widget
	//!< hierarchy with a Gtk::Window at the top. In general, you should only create
	//!< display specific resources when a widget has been realized, and you should free
	//!< those resources when the widget is unrealized.

	Gdk::Window* get_root_window() const;
	//!< The root window is useful for such purposes as creating a popup Gdk::Window
	//!< associated with the window. 
	//!< @return The Gdk::Window root window for the toplevel for this widget.
	//!<
	//!< <BR>In general, you should only create display specific resources when a widget
	//!< has been realized, and you should free those resources when the widget is
	//!< unrealized.

	Settings* get_settings() const;
	//!< Gets the settings object holding the settings (global property settings,
	//!< RC file information, etc) used for this widget.
	//!< @return The relevant Settings object.
	//!<
	//!< <BR>Note that this method can only be called when the Widget is attached to a
	//!< toplevel, since the settings object is specific to a particular Gdk::Screen.

	Clipboard* get_clipboard(Gdk::Atom selection = GDK_SELECTION_CLIPBOARD) const;
	//!< Returns the clipboard object for the given selection to be used with widget.
	//!< @param selection A Gdk::Atom which identifies the clipboard to use.
	//!< @return The appropriate clipboard object.
	//!<
	//!< <BR>The widget must have a Gdk::Display associated with it, and so must be attached
	//!< to a toplevel window. GDK_SELECTION_CLIPBOARD gives the default clipboard. Another
	//!< common value is GDK_SELECTION_PRIMARY, which gives the primary X selection. If no
	//!< clipboard already exists, a new one will be created. Once a clipboard object has
	//!< been created, it is persistent for all time. All clipboard objects are owned by
	//!< GTK+ and will be freed when GTK+ is removed from memory.

	Atk::Object* get_accessible() const;
	//!< Returns an accessible object for this widget.

	Gdk::EventMaskField get_events() const;
	//!< Gets the event mask for the widget (a bitfield containing flags from the Gdk::EventMask enumeration).
	//!< @return The event mask for the widget.
	//!<
	//!< <BR>These are the events that the widget will receive.
	
	void get_pointer(int *x, int *y) const;
	//!< Obtains the location of the mouse pointer in widget coordinates.
	//!< @param x The return location for the X coordinate, or null.
	//!< @param y The return location for the Y coordinate, or null.
	//!<
	//!< <BR>Widget coordinates are a bit odd; for historical reasons, they are defined as
	//!< Gdk::Window coordinates for widgets that are not Gtk::NO_WINDOW widgets, and are
	//!< relative to get_allocation().x and get_allocation().y for widgets that are
	//!< Gtk::NO_WINDOW widgets.

	Gdk::Point get_pointer() const;
	//!< Obtains the location of the mouse pointer in widget coordinates.
	//!< @return The widget coordinates stored in a Gdk::Point.
	//!<
	//!< <BR>Widget coordinates are a bit odd; for historical reasons, they are defined as
	//!< Gdk::Window coordinates for widgets that are not Gtk::NO_WINDOW widgets, and are
	//!< relative to get_allocation().x and get_allocation().y for widgets that are
	//!< Gtk::NO_WINDOW widgets.

	bool is_ancestor(Widget *ancestor) const;
	//!< Determines whether the widget is somewhere inside <EM>ancestor</EM>,
	//!< possibly within an intermediate container.
	//!< @param ancestor Another Widget.
	//!< @return <EM>true</EM> if ancestor contains the widget as a child, grandchild, great grandchild, etc.

	Style* get_style() const;
	//!< Returns the widget Style (see set_style().

	Style* rc_get_style() const;
	//!< Finds all matching RC styles for a given widget, composites them together, 
	//!< and then creates a Style representing the composite appearance. 
	//!< @return The resulting style. No refcount is added to the returned style,
	//!< so if you want to keep this style around, you should add a reference yourself.
	//!<
	//!< <BR>GTK+ actually keeps a cache of previously created styles, so a new style may not be created.

	RcStyle* get_modifier_style() const;
	//!< Returns the current modifier style for the widget (as set by modify_style()).
	//!< If no style has previously set, a new RcStyle will be created with all values
	//!< unset, and set as the modifier style for the widget. If you make changes to
	//!< this rc style, you must call modify_style(), passing in the returned rc style,
	//!< to make sure that your changes take effect.
	//!<
	//!< <B>Caution:</B> passing the style back to modify_style() will normally end up 
	//!< destroying it, because modify_style() copies the passed-in style and sets the
	//!< copy as the new modifier style, thus dropping any reference to the old modifier
	//!< style. Add a reference to the modifier style if you want to keep it alive.

	String get_composite_name() const;
	//!< Returns the composite name of the widget or a null String if the widget
	//!<  is not a composite child. 

	Pango::Context* get_pango_context() const;
	//!< Returns a Pango::Context with the appropriate colormap, font description and base
	//!< direction for the widget. Unlike the context returned by create_pango_context(),
	//!< this context is owned by the widget (it can be used as long as widget exists), and
	//!< will be updated to match any changes to the widget's attributes.
	//!<
	//!< If you create and keep a Pango::Layout using this context, you must deal with 
	//!< changes to the context by calling Pango::Layout::context_changed() on the layout in
	//!< response to the <EM>style_set</EM> and <EM>direction_set</EM> signals for the widget.

	TextDirection get_direction() const;
	//!< Returns the reading direction for the widget (see set_direction()).

	void style_get_property(const char *property_name, G::Value& value);
	//!< Gets the value of a style property of the widget.
	//!< @param property_name The name of a style property.
	//!< @param value The location to return the property value.

	void style_get(const char *first_property_name, ...) const;
	//!< Gets the values of multiple style properties of the widget.
	//!< @param first_property_name The name of the first property to get.
	//!< @param ... Pairs of property names and locations to return the property values,
	//!< starting with the location for first_property_name, terminated by null.
	//!<
	//!< <BR>Note the return locations are GValue*, not G::Value*.

	void path(String& path, String& path_reversed) const;
	//!< Obtains the full path to the widget. 
	//!< @param path The location to store the path string, or null.
	//!< @param path_reversed The location to store path string, or null.
	//!<
	//!< <BR>The path is simply the name of a widget and all its parents in the container hierarchy,
	//!< separated by periods. The name of a widget comes from get_name(). Paths are used to apply
	//!< styles to a widget in gtkrc configuration files. Widget names are the type of the widget
	//!< by default (e.g. "Button") or can be set to an application-specific value with set_name().
	//!< By setting the name of a widget, you allow users or theme authors to apply styles to that
	//!< specific widget in their gtkrc file. <EM>path_reversed</EM> fills in the path in reverse
	//!< order, i.e. starting with widget's name instead of starting with the name of widget's
	//!< outermost ancestor.

	void class_path(String& path, String& path_reversed) const;
	//!< Same as path(), but always uses the name of a widget's type,
	//!< never uses a custom name set with set_name().
	//!< @param path The location to store the path string, or null.
	//!< @param path_reversed The location to store path string, or null.

//! @}
//! @name Methods
//! @{

	void set_flags(WidgetFlagsField flags);
	//!< Turns on certain widget flags.
	//!< @param flags The widget flags to set.

	void unset_flags(WidgetFlagsField flags);
	//!< Turns off certain widget flags.
	//!< @param flags The widget flags to unset.

	void unparent();
	//!< Used in widget implementations; should be called by implementations of the
	//!< remove method on Gtk::Container, to dissociate a child from the container.

	void show();
	//!< Flags a widget to be displayed. Any widget that isn't shown will not appear on the screen.
	//!< If you want to show all the widgets in a container, it's easier to call widget_show_all()
	//!< on the container, instead of individually showing the widgets. 
	//!<
	//!< Remember that you have to show the container containing a widget, in addition to the
	//!< widget itself, before it will appear onscreen. When a toplevel container is shown, it
	//!< is immediately realized and mapped; other shown widgets are realized and mapped when
	//!< their toplevel container is realized and mapped.

	void hide();
	//!< Reverses the effects of show(), causing the widget to be hidden (invisible to the user).

	void show_now();
	//!< Shows a widget. If the widget is an unmapped toplevel widget (i.e. a Gtk::Window that
	//!< has not yet been shown), enter the main loop and wait for the window to actually be
	//!< mapped. Be careful; because the main loop is running, anything can happen during this
	//!< method.

	void show_all();
	//!< Recursively shows a widget, and any child widgets (if the widget is a container).

	void hide_all();
	//!< Recursively hides a widget and any child widgets.

	void map();
	//!< Used in widget implementations; causes the widget to be mapped if it isn't already
	//!< (visible on the screen).

	void unmap();
	//!< Used in widget implementations; causes the widget to be unmapped if it's currently
	//!< mapped (no longer visible on the screen).

	void realize();
	//!< Creates the GDK (windowing system) resources associated with a widget. For example,
	//!< a widget's GDK window will be created when a widget is realized. Normally realization
	//!< happens implicitly; if you show a widget and all its parent containers, then the
	//!< widget will be realized and mapped automatically. Realizing a widget requires all
	//!< the widget's parent widgets to be realized; calling realize() realizes the widget's
	//!< parents in addition to widget itself. If a widget is not yet inside a toplevel 
	//!< window when you realize it, bad things will happen.
	//!<
	//!< This method is primarily used in widget implementations, and isn't very useful
	//!< otherwise. Many times when you think you might need it, a better approach is to
	//!< connect to a signal that will be called after the widget is realized automatically,
	//!< such as <EM>expose_event</EM> signal. Or simply connect to the <EM>realize</EM>
	//!< signal specifying <EM>after</EM> as true in the signal's connect method.

	void unrealize();
	//!< Used in widget implementations; causes a widget to be unrealized (frees all
	//!< GDK resources associated with the widget, such as gtk_widget()->window).

	void queue_draw();
	//!< Equivalent to calling queue_draw_area() for the entire area of a widget.

	void queue_draw_area(int x, int y, int width, int height);
	//!< Invalidates the rectangular area of the widget defined by x, y, width and height by calling
	//!< Gdk::Window::invalidate_rect() on the widget's window and all its child windows.
	//!< @param x The X coordinate of upper-left corner of rectangle to redraw.
	//!< @param y The Y coordinate of upper-left corner of rectangle to redraw
	//!< @param width The width of region to draw.
	//!< @param height The height of region to draw.
	//!<
	//!< <BR>Once the main loop becomes idle (after the current batch of events
	//!< has been processed, roughly), the window will receive expose events for 
	//!< the union of all regions that have been invalidated.
	//!<
	//!< Normally you would only use this method in widget implementations. You 
	//!< might also use it, or Gdk::Window::invalidate_rect() directly, to schedule
	//!< a redraw of a DrawingArea or some portion thereof. Frequently you can just
	//!< call Gdk::Window::invalidate_rect() or Gdk::Window::invalidate_region() 
	//!< instead of this method. Those methods will invalidate only a single window,
	//!< instead of the widget and all its children.
	//!<
	//!< The advantage of adding to the invalidated region compared to simply drawing
	//!< immediately is efficiency; using an invalid region ensures that you only have
	//!< to redraw one time.

	void queue_draw_area(const Gdk::Rectangle& rectangle);
	//!< Invalidates the rectangular area of the widget defined by rectangle by calling
	//!< Gdk::Window::invalidate_rect() on the widget's window and all its child windows.
	//!< @param rectangle A rectangle that specifies the area of the widget to invalidate.

	void queue_resize();
	//!< This method is only for use in widget implementations. Flags a widget to have its size
	//!< renegotiated; should be called when a widget for some reason has a new size request.
	//!< For example, when you change the text in a Label, Label queues a resize to ensure
	//!< there's enough space for the new text.

	void size_request(Requisition *requisition);
	//!< Typically used when implementing a Container subclass; obtains the preferred size of the widget.
	//!< @param requisition A Requisition to be filled in.
	//!<
	//!< <BR> The container uses this information to arrange
	//!< its child widgets and decide what size allocations to give them with size_allocate().
	//!<
	//!< You can also call this function from an application, with some caveats. Most notably,
	//!< getting a size request requires the widget to be associated with a screen, because font
	//!< information may be needed. Multihead-aware applications should keep this in mind. Also
	//!< remember that the size request is not necessarily the size a widget will actually be
	//!< allocated. See also get_child_requisition().

	void size_allocate(const Allocation& allocation);
	//!< This method is only used by Container subclasses to assign a size and position
	//!< to their child widgets.
	//!< @param allocation The position and size to be allocated to the widget.

	void add_accelerator(const String& accel_signal, AccelGroup& accel_group, const AccelKey& accel_key);
	//!< Installs an accelerator for this widget in accel_group that causes accel_signal
	//!< to be emitted if the accelerator is activated.
	//!< @param accel_signal The widget signal to emit on accelerator activation.
	//!< @param accel_group The accelerator group for this widget, added to its toplevel.
	//!< @param accel_key An AccelKey that holds the accelerator key, modifier and flag values.
	//!<
	//!< <BR>The accel_group needs to be added to the widget's toplevel via Gtk::Window::add_accel_group(),
	//!< and the signal must be of type G_RUN_ACTION. Accelerators added through this function are not user
	//!< changeable during runtime. If you want to support accelerators that can be changed by the user,
	//!< use Gtk::AccelMap::add_entry() and set_accel_path() or Gtk::MenuItem::set_accel_path() instead.

	bool remove_accelerator(AccelGroup& accel_group, const AccelKey& accel_key);
	//!< Removes an accelerator from the widget previously installed with add_accelerator().
	//!< @param accel_group The accel group for this widget.
	//!< @param accel_key An AccelKey that holds the accelerator key, modifier and flag values.
	//!< @return Whether an accelerator was installed and could be removed.

	void set_accel_path(const char *accel_path, AccelGroup& accel_group);
	//!< Given an accelerator group <EM>accel_group</EM> and an accelerator path <EM>accel_path</EM>,
	//!< sets up an accelerator in accel_group so whenever the key binding that is defined for accel_path
	//!< is pressed, the widget will be activated. 
	//!< @param accel_path The path used to look up the the accelerator.
	//!< @param accel_group The accelerator group.
	//!<
	//!< <BR>This removes any accelerators (for any accelerator group) installed by previous calls
	//!< to set_accel_path(). Associating accelerators with paths allows them to be modified by the
	//!< user and the modifications to be saved for future use. (See Gtk::AccelMap_save().)
	//!<
	//!< This method is a low level function that would most likely be used by a menu creation system
	//!< like ItemFactory. If you use ItemFactory, setting up accelerator paths will be done automatically.
	//!< Even when you you aren't using ItemFactory, if you only want to set up accelerators on menu items
	//!< Gtk::MenuItem::set_accel_path() provides a somewhat more convenient interface.

	bool list_accel_closures(std::vector<GClosure*>& closures);
	//!< Lists the closures used by the widget for accelerator group connections with
	//!< Gtk::AccelGroup::connect(). /* T
	//!< @param closures A reference to a vector of GClosure* to hold the list of closures.
	//!< @return <EM>true</EM> if the vector is not empty.
	//!<
	//!< <BR>The closures can be used to monitor accelerator changes on the widget, by connecting
	//!< to the <EM>accel_changed</EM> signal of the AccelGroup of a closure, which can be found out
	//!< with Gtk::AccelGroup::from_accel_closure().

	int send_expose(const Gdk::EventExpose& event);
	//!< This rarely-used method is used to emit an <EM>expose_event</EM> signal on the widget.
	//!< @param event A Gdk::GdkEventExpose.
	//!< @return The return from the event signal emission (true if the event was handled).
	//!<
	//!< <BR>This method is not normally used directly. The only time it is used is when 
	//!< propagating an expose event to a child NO_WINDOW widget, and that is normally
	//!< done using Gtk::Container::propagate_expose(). 
	//!<
	//!< If you want to force an area of a window to be redrawn, use Gdk::Window::invalidate_rect()
	//!< or Gdk::Window::invalidate_region(). To cause the redraw to be done immediately, follow 
	//!< that call with a call to Gdk::Window::process_updates().

	bool mnemonic_activate(bool group_cycling);
	//!< Actviates the widget if it's suitable for mnemonic actviaton.
	//!< @param group_cycling
	//!< @return <EM>true</EM> if the widget was activated.

	bool event(const Gdk::Event& event);
	//!< This rarely-used method is used to emit the event signals on a widget (those signals
	//!< should never be emitted without using this method to do so).
	//!< @param event A Gdk::Event.
	//!< @return The return from the event signal emission (true if the event was handled).
	//!<
	//!< <BR>If you want to synthesize an event though, don't use this function; instead,
	//!< use gtk_main_do_event() so the event will behave as if it were in the event queue.
	//!< Don't synthesize expose events; instead, use Gdk::Window::invalidate_rect() to
	//!< invalidate a region of the window.

	bool activate();
	//!< For widgets that can be activated (buttons, menu items, etc) this method activates them.
	//!< @return <EM>true</EM> if the widget was activatable.
	//!<
	//!< <BR>Activation is what happens when you press <EM>Enter</EM> on a widget during key navigation;
	//!< clicking a button, selecting a menu item, etc. If the widget isn't activatable, this method
	//!< returns false.

	bool set_scroll_adjustments(Adjustment *hadjustment, Adjustment *vadjustment);
	//!< Sets the widget's scroll adjustments.
	//!< @param hadjustment An adjustment for horizontal scrolling, or null.
	//!< @param vadjustment An adjustment for vertical scrolling, or null.
	//!< @return <EM>true</EM> if the widget supports scrolling.
	//!<
	//!< <BR>For widgets that support scrolling, sets the scroll adjustments and returns true.
	//!< For widgets that don't support scrolling, does nothing and returns false. Widgets that
	//!< don't support scrolling can be scrolled by placing them in a Viewport, which does 
	//!< support scrolling.

	void reparent(Widget& new_parent);
	//!< Moves a widget from one Container to another, handling reference count issues
	//!< to avoid destroying the widget.
	//!< @param new_parent A Container to move the widget into.

	bool intersect(const Gdk::Rectangle& area, Gdk::Rectangle *intersection);
	//!< Computes the intersection of a widget's area and <EM>area</EM>, storing the intersection
	//!< in <EM>intersection</EM>, and returns true if there was an intersection.
	//!< @param area A rectangle.
	//!< @param intersection The rectangle to store intersection of the widget and <EM>area</EM>.
	//!< @return <EM>true</EM> if there was an intersection.
	//!<
	//!< <BR>The intersection may be null if you're only interested in whether there was an intersection.

	Gdk::Rectangle intersect(const Gdk::Rectangle& area);
	//!< Computes the intersection of a widget's area and <EM>area</EM>, and returns
	//!< the intersection as a rectanlge.
	//!< that stores .
	//!< @param area A rectangle.
	//!< @return A rectangle storing the intersection if there was an intersection.
	//!<
	//!< <BR>The returned rectangle will be empty if there was no intersection.

	Pointer<Gdk::Region> intersect(Gdk::Region& region);
	//!< Computes the intersection of a widget's area and <EM>region</EM>,
	//!< and returns the intersection as a new Gdk::Region.
	//!< @param region a Gdk::Region.
	//!< @return A smart pointer to a new Gdk::Region holding the intersection of the widget and <EM>region</EM>.
	//!<
	//!< <BR><EM>region</EM> must be in the same coordinate system as the widget's allocation.
	//!< That is, relative to the widget's GDK window for NO_WINDOW widgets; relative to
	//!< the parent window of widget's GDK window for widgets with their own window. The
	//!< coordinates returned are relative to the widget's GDK window for NO_WINDOW widgets,
	//!< and relative to the parent window of widget's GDK window for widgets with their
	//!< own window. The returned region may be empty, use Gdk::Region::empty() to check.

	void freeze_child_notify();
	//!< Stops the emission of <EM>child_notify</EM> signals on the widget. The signals are
	//!< queued until thaw_child_notify() is called on the widget.

	void child_notify(const char *child_property);
	//!< Emits a <EM>child_notify</EM> signal for the child property <EM>child_property</EM> on the widget.
	//!< @param child_property The name of a child property installed on the class of widget's parent.

	void thaw_child_notify();
	//!< Reverts the effect of a prevoious call to freeze_child_notify(). This causes all queued
	//!< <EM>child_notify</EM> signals on widget to be emitted.
	
	void grab_focus();
	//!< Causes the widget to have the keyboard focus for the Window it's inside. The widget
	//!< must be a focusable widget, such as an Entry; something like Frame won't work. More
	//!< precisely, it must have the Gtk::CAN_FOCUS flag set.

	void grab_default();
	//!< Causes the widget to become the default widget. The widget must have the Gtk::CAN_DEFAULT
	//!< flag set; typically you have to set this flag yourself by calling set_flags(Gtk::CAN_DEFAULT).
	//!< The default widget is activated when the user presses <EM>Enter</EM> in a window. Default
	//!< widgets must be activatable, that is, activate() should affect them.

	void set_name(const String& name);
	//!< Widgets can be named, which allows you to refer to them in a gtkrc file.
	//!< @param name The name for the widget.
	//!<
	//!< <BR>You can apply a style to widgets with a particular name in the gtkrc file. See the
	//!< GTK+ documentation for gtkrc files (on the same page as the docs for GtkRcStyle).

	void set_state(StateType state);
	//!< Used in widget implementations; sets the state of the widget (insensitive, prelighted, etc).
	//!< @param state The new state for the widget.
	//!<
	//!< <BR>Usually you should set the state using wrapper functions such as set_sensitive().

	void set_sensitive(bool sensitive);
	//!< Sets the sensitivity of the widget.
	//!< @param sensitive <EM>true</EM> to make the widget sensitive.
	//!<
	//!< <BR>A widget is sensitive if the user can interact with it. Insensitive widgets are
	//!< <EM>grayed out</EM> and the user can't interact with them. Insensitive widgets are 
	//!< known as <EM>inactive, disabled, or ghosted</EM> in some other toolkits.

	void set_app_paintable(bool app_paintable);
	//!< Sets the Gtk::APP_PAINTABLE flags on the widget.
	//!< @param app_paintable <EM>true</EM> if Gtk::APP_PAINTABLE should be set.
	//!<
	//!< <BR>Must be set on widgets whose window the application directly draws on, 
	//!< in order to keep GTK+ from overwriting the drawn stuff.

	void set_double_buffered(bool double_buffered);
	//!< Widgets are double buffered by default; you can use this function to turn off the buffering.
	//!< @param double_buffered <EM>true</EM> to double-buffer a widget.
	//!<
	//!< <BR><EM>Double buffered</EM> simply means that Gdk::Window::begin_paint() and
	//!< Gdk::Window::end_paint() are called automatically around expose events sent to
	//!< the widget. Gdk::Window::begin_paint() diverts all drawing to a widget's window
	//!< to an offscreen buffer, and Gdk::Window::end_paint() draws the buffer to the 
	//!< screen. The result is that users see the window update in one smooth step, and 
	//!< don't see individual graphics primitives being rendered. In very simple terms, 
	//!< double buffered widgets don't flicker, so you would only use this function to turn
	//!< off double buffering if you had special needs and really knew what you were doing.

	void set_redraw_on_allocate(bool redraw_on_allocate);
	//!< When a widgets size allocation changes, sets whether the entire widget is queued
	//!< for drawing or not.
	//!< @param redraw_on_allocate Set <EM>true</EM> to redraw the entire widget when it's resized,
	//!<                           and <EM>false</EM> to only redraw the new portion of the widget
	//!<
	//!< <BR>By default, this setting is true and the entire widget is redrawn on every size change. 
	//!< If your widget leaves the upper left unchanged when made bigger, turning this setting on 
	//!< will improve performance. Note that for NO_WINDOW widgets setting this flag to false turns
	//!< off all allocation on resizing: the widget will not even redraw if its position changes;
	//!< this is to allow containers that don't draw anything to avoid excess invalidations. If you
	//!< set this flag on a NO_WINDOW widget that does draw on the widget's GDK window, you are 
	//!< responsible for invalidating both the old and new allocation of the widget when the widget
	//!< is moved and responsible for invalidating regions newly when the widget increases size.

	void set_parent(Widget& parent);
	//!< Sets the container as the parent of widget, and takes care of some details such as
	//!< updating the state and style of the child to reflect its new location. 
	//!< @param parent The parent container.
	//!<
	//!< <BR>This method is useful only when implementing subclasses of Container. The opposite
	//!< method is unparent().

	void set_parent_window(Gdk::Window *parent_window);
	//!< Sets a non default parent window for widget.
	//!< @param parent_window The new parent window.

	void set_child_visible(bool is_visible);
	//!< Sets whether the widget should be mapped along with its parent when its parent
	//!< is mapped and the widget has been shown with show().
	//!< @param is_visible If <EM>true</EM>, the widget should be mapped along with its parent.
	//!<
	//!< <BR>The child visibility can be set for a widget before it is added to a container
	//!< with set_parent(), to avoid mapping children unnecessary before immediately 
	//!< unmapping them. However it will be reset to its default state of true when the
	//!< widget is removed from a container. 
	//!<
	//!< Note that changing the child visibility of a widget does not queue a resize on 
	//!< the widget. Most of the time, the size of a widget is computed from all visible 
	//!< children, whether or not they are mapped. If this is not the case, the container
	//!< can queue a resize itself. This method is only useful for container implementations
	//!< and never should be called by an application.

	bool child_focus(DirectionType direction);
	//!< Moves the focus to the child widget.
	//!< @param direction The direction of focus movement. 
	//!< @return <EM>true</EM> if the focus ended up inside the widget.
	//!<	
	//!< <BR>This method is used by custom widget implementations; if you're writing an
	//!< application, you'd use grab_focus() to move the focus to a particular widget,
	//!< and Gtk::Container::set_focus_chain() to change the focus tab order. So you may
	//!< want to investigate those methods instead.
	//!<
	//!< <EM>child_focus()</EM> is called by containers as the user moves around the window
	//!< using keyboard shortcuts. <EM>direction</EM> indicates what kind of motion is 
	//!< taking place (up, down, left, right, tab forward, tab backward). <EM>child_focus()</EM>
	//!< invokes the "focus" signal on the Widget; widgets override the default handler for this
	//!< signal in order to implement appropriate focus behavior. The "focus" default handler 
	//!< for a widget should return true if moving in <EM>direction</EM> left the focus on a
	//!< focusable location inside that widget, and false if moving in <EM>direction</EM> moved
	//!< the focus outside the widget. If returning true, widgets normally call grab_focus() to
	//!< place the focus accordingly; if returning false, they don't modify the current focus
	//!< location. 

	void set_size_request(int width, int height);
	//!< Sets the minimum size of a widget; that is, the widget's size request will be width by height.
	//!< @param width The width the widget should request, or -1 to unset.
	//!< @param height The height widget should request, or -1 to unset.
	//!<
	//!< <BR>You can use this method to force a widget to be either larger or smaller than it
	//!< normally would be. In most cases, set_default_size() is a better choice for toplevel
	//!< windows than this method; setting the default size will still allow users to shrink
	//!< the window. Setting the size request will force them to leave the window at least as
	//!< large as the size request. When dealing with window sizes, 
	//!< Gtk::Window::set_geometry_hints() can be a useful method as well. 
	//!<
	//!< Note the inherent danger of setting any fixed size - themes, translations into other 
	//!< languages, different fonts, and user action can all change the appropriate size for
	//!< a given widget. So, it's basically impossible to hardcode a size that will always be
	//!< correct.
	//!<
	//!< The size request of a widget is the smallest size a widget can accept while still 
	//!< functioning well and drawing itself correctly. However in some strange cases a 
	//!< widget may be allocated less than its requested size, and in many cases a widget 
	//!< may be allocated more space than it requested. If the size request in a given 
	//!< direction is -1 (unset), then the "natural" size request of the widget will be
	//!< used instead. Widgets can't actually be allocated a size less than 1 by 1, but 
	//!< you can pass 0,0 to this function to mean "as small as possible."

	void set_events(Gdk::EventMaskField events);
	//!< Sets the event mask (see Gdk::EventMask) for a widget. 
	//!< @param events The event mask.
	//!<
	//!< <BR>The event mask determines which events a widget will receive. Keep in mind that 
	//!< different widgets have different default event masks, and by changing the event mask
	//!< you may disrupt a widget's functionality, so be careful. This method must be called
	//!< while a widget is unrealized. Consider add_events() for widgets that are already 
	//!< realized, or if you want to preserve the existing event mask. This method can't be
	//!< used with Gtk::NO_WINDOW widgets; to get events on those widgets, place them inside
	//!< an EventBox and receive events on the event box.

	void add_events(Gdk::EventMaskField events);
	//!< Adds the events in the bitfield <EM>events</EM> to the event mask for the widget (see set_events()).
	//!< @param events An event mask, see Gdk::EventMask.

	void set_extension_events(Gdk::ExtensionMode mode);
	//!< Sets the extension events mask to <EM>mode</EM> (see Gdk::ExtensionMode and
	//!< Gdk::Input::set_extension_events()).
	//!< @param mode The extension events to receive.

	void set_colormap(Gdk::Colormap& colormap);
	//!< Sets the colormap for the widget to <EM>colormap</EM>. 
	//!< @param colormap A colormap.
	//!<
	//!< <BR>The widget must not have been previously realized. This probably should only be used 
	//!< from a constructor for the widget.

	bool translate_coordinates(Widget &src_widget, int src_x, int src_y, int *dest_x, int *dest_y) const;
	//!< Translate coordinates relative to src_widget's allocation to coordinates
	//!< relative to this widget's allocation.
	//!< @param src_widget The source widget.
	//!< @param src_x The X position relative to src_widget.
	//!< @param src_y The Y position relative to src_widget.
	//!< @param dest_x The location to store X position relative to this widget.
	//!< @param dest_y The location to store Y position relative to this widget.
	//!< @return <EM>false</EM> if either widget was not realized, or there was no common ancestor.
	//!< In this case, nothing is stored in <EM>dest_x</EM> and <EM>dest_y</EM>. Otherwise <EM>true</EM>.
	//!<
	//!< <BR>In order to perform this operation, both widgets must be realized, and must share a common toplevel.

	void set_style(Style& style);
	//!< Sets the Style for the widget.
	//!< @param style A Gtk::Style, or null to remove the effect of a previous
	//!<              set_style() and go back to the default style.
	//!<
	//!< <BR>You probably don't want to use this function; it interacts badly with themes, 
	//!< because themes work by replacing the Style. Instead, use modify_style().

	void ensure_style();
	//!< Ensures that the widget has a style. Not a very useful method; most of the time,
	//!< if you want the style, the widget is realized, and realized widgets are guaranteed
	//!< to have a style already.

	void modify_style(RcStyle& style);
	//!< Modifies style values on the widget. 
	//!< @param style The RcStyle holding the style modifications.
	//!<
	//!< <BR>Modifications made using this method take precedence over style values set
	//!< via an RC file, however, they will be overriden if a style is explicitely set on
	//!< the widget using set_style(). The RcStyle structure is designed so each field can
	//!< either be set or unset, so it is possible, using this method, to modify some style
	//!< values and leave the others unchanged.
	//!<
	//!< Note that modifications made with this method are not cumulative with previous 
	//!< calls to modify_style() or with such functions as modify_fg(). If you wish to 
	//!< retain previous values, you must first call get_modifier_style(), make your 
	//!< modifications to the returned style, then call modify_style() with that style.
	//!< On the other hand, if you first call modify_style(), subsequent calls to such 
	//!< methods as modify_fg() will have a cumulative effect with the initial modifications.

	void modify_fg(StateType state, const Gdk::Color* color);
	//!< Sets the foreground color for the widget in a particular state.
	//!< @param state The state for which to set the foreground color.
	//!< @param color The color to assign (does not need to be allocated), or null
	//!<              to undo the effect of previous calls to modify_fg().
	//!<
	//!< <BR>All other style values are left untouched (se also modify_style()).

	void modify_bg(StateType state, const Gdk::Color *color);
	//!< Sets the background color for the widget in a particular state.
	//!< @param state The state for which to set the background color.
	//!< @param color The color to assign (does not need to be allocated), or null
	//!<              to undo the effect of previous calls to modify_bg().
	//!<
	//!< <BR>All other style values are left untouched (see also modify_style()).

	void modify_text(StateType state, const Gdk::Color *color);
	//!< Sets the text color for the widget in a particular state.
	//!< @param state The state for which to set the text color.
	//!< @param color The color to assign (does not need to be allocated), or null
	//!<              to undo the effect of previous calls to modify_text().
	//!<
	//!< <BR>All other style values are left untouched. The text color is the foreground
	//!< color used along with the base color (see modify_base()) for widgets such as
	//!< Entry and TextView. See also modify_style().

	void modify_base(StateType state, const Gdk::Color *color);
	//!< Sets the base color for the widget in a particular state.
	//!< @param state The state for which to set the base color.
	//!< @param color The color to assign (does not need to be allocated), or null
	//!<              to undo the effect of previous calls to of modify_base().
	//!<
	//!< <BR>All other style values are left untouched. The base color is the background 
	//!< color used along with the text color (see modify_text()) for widgets such as 
	//!< Entry and TextView. See also modify_style().

	void modify_font(const Pango::FontDescription *font_desc);
	//!< Sets the font to use for the widget.
	//!< @param font_desc The font description to use, or null to undo the effect
	//!< of previous calls to modify_font().
	//!<
	//!< <BR>All other style values are left untouched. See also modify_style().

	Pointer<Pango::Context> create_pango_context();
	//!< Creates a new Pango::Context with the appropriate colormap, font description,
	//!< and base direction for drawing text for this widget (see also get_pango_context()).
	//!< @return A smart pointer to the new Pango::Context.

	Pointer<Pango::Layout> create_pango_layout(const String& text);
	//!< Creates a new Pango::Layout with the appropriate colormap, font description,
	//!< and base direction for drawing text for this widget.
	//!< @param text The text to set on the layout (can be a null String).
	//!< @return A smart pointer to the new Pango::Layout.
	//!<
	//!< <BR>If you keep a Pango::Layout created in this way around, in order to notify
	//!< the layout of changes to the base direction or font for this widget, you must
	//!< call Pango::Layout::context_changed() in response to the <EM>style_set</EM>
	//!< and <EM>direction_set</EM> signals for the widget.

	Pointer<Gdk::Pixbuf> render_icon(const char *stock_id, IconSize size, const char *detail = 0);
	//!< A convenience method that uses the theme engine and RC file settings for the widget
	//!< to look up stock_id and render it to a pixbuf. 
	//!< @param stock_id A stock ID.
	//!< @param size A stock size.
	//!< @param detail The render detail to pass to a theme engine.
	//!< @return A smart pointer to the new pixbuf, or null if the stock ID wasn't known.
	//!<
	//!< <BR><EM>stock_id</EM> should be a stock icon ID such as GTK_STOCK_OPEN or GTK_STOCK_OK.
	//!< <EM>size</EM> should be a size such as Gtk::ICON_SIZE_MENU. <EM>detail</EM> should be a
	//!< string that identifies the widget or code doing the rendering, so that theme engines can
	//!< special-case rendering for that widget or code. The pixels in the returned Gdk::Pixbuf 
	//!< are shared with the rest of the application and should not be modified.

	void set_composite_name(const String& name);
	//!< Sets a widgets composite name. 
	//!< @param name The name to set.
	//!<
	//!< <BR>The widget must be a composite child of its parent (see push_composite_child()).

	void reset_rc_styles();
	//!< Reset the styles of the widget and all descendents, so when they are looked up again,
	//!< they get the correct values for the currently loaded RC file settings. This method
	//!< is not useful for applications

	void set_direction(TextDirection dir);
	//!< Sets the reading direction on a particular widget. 
	//!< @param dir The new direction.
	//!<
	//!< <BR>This direction controls the primary direction for widgets containing text,
	//!< and also the direction in which the children of a container are packed. The
	//!< ability to set the direction is present in order so that correct localization
	//!< into languages with right-to-left reading directions can be done. Generally, 
	//!< applications will let the default reading direction present, except for 
	//!< containers where the containers are arranged in an order that is explicitely
	//!< visual rather than logical (such as buttons for text justification). If the
	//!< direction is set to Gtk::TEXT_DIR_NONE, then the value set by 
	//!< set_default_direction() will be used.

	void shape_combine_mask(const Gdk::Bitmap& shape_mask, int offset_x, int offset_y);
	//!< Sets a shape for this widget's GDK window.
	//!< @param shape_mask The shape to be added.
	//!< @param offset_x The X position of shape mask with respect to window.
	//!< @param offset_y The Y position of shape mask with respect to window.
	//!<
	//!< <BR>This allows for transparent windows etc., see Gdk::Window::shape_combine_mask()
	//!< for more information.

 	void shape_combine_mask();
	//!< Removes an exisitng shape from this widget's GDK window.

//! @}

	static const Style* get_default_style();
	//!< Returns the default style used by all widgets initially.
	//!< @return The default style. This Style object is owned by GTK+ and should
	//!< not be modified or unreferenced.

	static Gdk::Colormap* get_default_colormap();
	//!< Returns the default colormap used to create widgets.

	static const Gdk::Visual* get_default_visual();
	//!< Returns the visual of the default colormap. Not really useful; used to be useful
	//!< before Gdk::Colormap::get_visual() existed.

	static TextDirection get_default_direction();
	//!< Returns the current default reading direction (see set_default_direction()).

	static void push_colormap(Gdk::Colormap& cmap);
	//!< Pushes <EM>cmap</EM> onto a global stack of colormaps; the topmost colormap on the stack
	//!< will be used to create all widgets.
	//!< @param cmap A Gdk::Colormap
	//!<
	//!< <BR>Remove <EM>cmap</EM> with pop_colormap(). There's little reason to use this method.

	static void push_composite_child();
	//!< A composite child is a child that's an implementation detail of the container
	//!< it's inside and should not be visible to people using the container. Composite
	//!< children aren't treated differently by GTK but e.g. GUI builders might want to
	//!< treat them in a different way.

	static void pop_composite_child();
	//!< Cancels the effect of a previous call to push_composite_child().

	static void pop_colormap();
	//!< Removes a colormap pushed with push_colormap().

	static void set_default_colormap(Gdk::Colormap *colormap);
	//!< Sets the default colormap to use when creating widgets.
	//!< @param colormap A Gdk::Colormap.
	//!<
	//!< <BR>push_colormap() is a better method to use if you only want to affect
	//!< a few widgets, rather than all widgets.

	static void set_default_direction(TextDirection  dir);
	//!< Sets the default reading direction for widgets where the direction has not been
	//!< explicitly set by set_direction().
	//!< @param dir The new default direction. This cannot be Gtk::TEXT_DIR_NONE.


//! @name Keyboard and Pointer Grab Methods
//! @{

	Gdk::GrabStatus keyboard_grab(bool owner_events = false, unsigned int time = GDK_CURRENT_TIME);
	//!< Grabs the keyboard so that all events are passed to this widget until the keyboard
	//!< is ungrabbed with Gdk::keyboard_ungrab().
	//!< @param owner_events If <EM>false</EM> then all keyboard events are reported with respect the
	//!<                     widget. If <EM>true</EM> then keyboard events for this application are
	//!<                     reported as normal, but keyboard events outside this application are
	//!<                     reported with respect to the widget. Both key press and key release events
	//!<                     are always reported, independant of the event mask set by the application.
	//!< @param time A timestamp from a Gdk::Event, or GDK_CURRENT_TIME if no timestamp is available.
	//!< @return Gdk::GRAB_SUCCESS if the grab was successful.
	//!<
	//!< <BR>This overrides any previous keyboard grab by this client. The widget's Gdk::Window
	//!< will own the grab (the grab window).

	Gdk::GrabStatus pointer_grab(Gdk::EventMaskField event_mask, Widget *confine_to = 0, Gdk::Cursor *cursor = 0,
	                             bool owner_events = false, unsigned int time = GDK_CURRENT_TIME);
	//!< Grabs the pointer (usually a mouse) so that all events are passed to this widget until
	//!< the pointer is ungrabbed with Gdk::pointer_ungrab(), or the grab widget becomes unviewable.
	//!< @param event_mask Specifies the event mask, which is used in accordance with owner_events.
	//!< @param confine_to If non-null, the pointer will be confined to this widget during the grab. If the
	//!<                   pointer is outside confine_to, it will automatically be moved to the closest edge
	//!<                   of confine_to and enter and leave events will be generated as necessary.
	//!< @param cursor The cursor to display while the grab is active. If this is null then the normal
	//!<               cursors are used for the widget and its descendants, and the cursor for the widget
	//!<               is used for all other windows.
	//!< @param owner_events If <EM>false</EM> then all pointer events are reported with respect to the
	//!<                     widget and are only reported if selected by event_mask. If <EM>true</EM>
	//!<                     then pointer events for this application are reported as normal, but pointer
	//!<                     events outside this application are reported with respect to the widget and
	//!<                     only if selected by event_mask. In either mode, unreported events are discarded.
	//!< @param time The timestamp of the event which led to this pointer grab. This usually comes from a
	//!<              Gdk::EventButton, though GDK_CURRENT_TIME can be used if the time isn't known.
	//!< @return Gdk::GRAB_SUCCESS if the grab was successful.
	//!<
	//!< <BR>This overrides any previous pointer grab by this client. The widget's Gdk::Window
	//!< will own the grab (the grab window). Pointer grabs are used for operations which need
	//!< complete control over mouse events, even if the mouse leaves the application. For 
	//!< example in GTK+ it is used for Drag and Drop, for dragging the handle in the HPaned
	//!< and VPaned widgets. Note that if the event mask of an X window has selected both button
	//!< press and button release events, then a button press event will cause an automatic 
	//!< pointer grab until the button is released. X does this automatically since most 
	//!< applications expect to receive button press and release events in pairs. It is 
	//!< equivalent to a pointer grab on the window with owner_events set to true.

//! @}
//! @name Selection Methods (from gtkselection.h)
//! @{

	bool selection_owner_get(Gdk::Atom selection);
	//!< Returns whether the widget owns <EM>selection</EM>.
	//!< @param selection An interned atom representing the selection to check.
	//!< @return <EM>true</EM> if this widget owns <EM>selection</EM>.

	bool selection_owner_set(Gdk::Atom selection, unsigned int time, const Gdk::Display *display = 0);
	//!< Claim ownership of a given selection for a particular widget.
	//!< @param selection An interned atom representing the selection to claim.
	//!< @param time A timestamp with which to claim the selection, or GDK_CURRENT_TIME.
	//!< @param display The Gdk::Display where the selection is set, or null for the default display.
	//!< @return <EM>true</EM> if the operation succeeded.

	void selection_add_target(Gdk::Atom selection, Gdk::Atom target, unsigned int info);
	//!< Adds the specified target to the list of supported targets for the widget and selection.
	//!< @param selection The selection.
	//!< @param target The target to add.
	//!< @param info An unsigned integer which will be passed back to the application.

	void selection_add_target(Gdk::Atom selection, const TargetEntry& entry);
	//!< Adds the specified target to the list of supported targets for the widget and selection.
	//!< @param selection The selection.
	//!< @param entry The target entry to add.

	void selection_add_targets(Gdk::Atom selection, const std::vector<TargetEntry>& targets);
	//!< Adds the targets specified in <EM>targets</EM> to the list of supported targets
	//!< for the widget and selection.
	//!< @param selection The selection.
	//!< @param targets A reference to a vector of TargetEntry that holds the targets to add.

	void selection_clear_targets(Gdk::Atom selection);
	//!< Remove all targets registered for the given selection for the widget.
	//!< @param selection An atom representing a selection.

	bool selection_convert(Gdk::Atom selection, Gdk::Atom target, unsigned int time = GDK_CURRENT_TIME);
	//!< Requests the contents of a selection.
	//!< @param selection Which selection to get.
	//!< @param target Form of information desired (e.g., STRING).
	//!< @param time Time of request (usually of triggering event), or you could use GDK_CURRENT_TIME.
	//!< @return <EM>true</EM> if the request succeeded. <EM>false</EM> if we could not process
	//!< the request (e.g. there was already a request in process for this widget).
	//!<
	//!< <BR>When received, a <EM>selection_received</EM> signal will be generated.

	void selection_remove_all();
	//!< Removes all handlers and unsets ownership of all selections for the widget. Called when
	//!< the widget is being destroyed. This method will not generally be called by applications.

//! @}

	static bool selection_owner_unset(Gdk::Atom selection, unsigned int time, const Gdk::Display *display = 0);
	//!< Releases ownership of a given selection.
	//!< @param selection An interned atom representing the selection to release.
	//!< @param time A timestamp with which to claim the selection, or GDK_CURRENT_TIME.
	//!< @param display The Gdk::Display where the selection is set, or null for the default display.
	//!< @return <EM>true</EM> if the operation succeeded.

//! @name Target Drag-and-Drop Methods (from gtkdnd.h)
//! @{

	void drag_get_data(DragContext& context, Gdk::Atom target, unsigned int time = GDK_CURRENT_TIME);
	//!< Gets the data associated with a drag.
	//!< @param context The drag context.
	//!< @param target The target (form of the data) to retrieve.
	//!< @param time A timestamp for retrieving the data.
	//!<
	//!< <BR>When the data is received or the retrieval fails, GTK+ will emit a <EM>drag_data_received</EM>
	//!< signal. Failure of the retrieval is indicated by Gtk::SelectionData::is_valid() returning <EM>false</EM>.
	//!< However, when drag_get_data() is called implicitely because the Gtk::DRAG_DEFAULT_DROP was set, then
	//!< the widget will not receive notification of failed drops and Gtk::SelectionData::is_valid() will be
	//!< undefined.	<EM>time</EM> will generally be the time received in a <EM>drag_data_motion</EM> or
	//!< <EM>drag_data_drop</EM> signal.

	void drag_highlight();
	//!< Draws a highlight around the widget. This will attach handlers to <EM>expose_event</EM> and
	//!< draw, so the highlight will continue to be displayed until drag_unhighlight() is called.

	void drag_unhighlight();
	//!< Removes a highlight set by drag_highlight() from the widget.

	void drag_dest_set(DestDefaultsField flags, const TargetEntry& target, Gdk::DragActionField actions);
	//!< Sets the widget as a potential drop destination. 
	//!< @param flags The flags that specify what actions GTK+ should take on behalf of
        //!<              a widget for drops onto that widget. 
	//!< @param target A TargetEntry indicating the drop type that this widget will accept. 
	//!< @param actions A bitmask of possible actions for a drop onto this widget.
	//!< 
	//!< <BR>The targets and actions fields only are used if DEST_DEFAULT_MOTION or
	//!< DEST_DEFAULT_DROP are given. 
	
	void drag_dest_set(DestDefaultsField flags, const std::vector<TargetEntry>& targets, Gdk::DragActionField actions);
	//!< Sets the widget as a potential drop destination. 
	//!< @param flags The flags that specify what actions GTK+ should take on behalf of
        //!<              a widget for drops onto that widget. 
	//!< @param targets A vector of TargetEntry indicating the drop types that this widget will accept. 
	//!< @param actions A bitmask of possible actions for a drop onto this widget.
	//!< 
	//!< <BR>The targets and actions fields only are used if DEST_DEFAULT_MOTION or 
	//!< DEST_DEFAULT_DROP are given. 

	void drag_dest_set_proxy(Gdk::Window *proxy_window, Gdk::DragProtocol protocol, bool use_coordinates);
	//!< Sets the widget as a proxy for drops to another window.
	//!< @param proxy_window The window to which to forward drag events
	//!< @param protocol The drag protocol which the proxy_window accepts (You can use
	//!<                 gdk_drag_get_protocol() to determine this).
	//!< @param use_coordinates If <EM>true</EM>, send the same coordinates to the destination, 
	//!<                        because it is an embedded subwindow.

	void drag_dest_unset();
	//!< Clears information about a drop destination set with drag_dest_set().
	//!< The widget will no longer receive notification of drags. 

	Gdk::Atom drag_dest_find_target(const DragContext& context, const TargetList *target_list = 0);
	//!< Looks for a match between context.targets() and the target_list,
	//!< returning the first matching target, otherwise returning GDK_NONE. 
	//!< @param context A drag context.
	//!< @param target_list A TargetList of droppable targets, or null to use drag_dest_get_target_list().
	//!< @return The first target that the source offers and the dest can accept, or GDK_NONE.
	//!<
	//!< <BR>The target_list should usually be the return value from drag_dest_get_target_list(),
	//!< but some widgets may have different valid targets for different parts of the widget; 
	//!< in that case, they will have to implement a drag_motion handler that passes the correct
	//!< target list to this function.

	Pointer<TargetList> drag_dest_get_target_list() const;
	//!< Returns the list of targets this widget can accept from drag-and-drop.
	//!< @return A smart pointer to the TargetList, or null if none.

	void drag_dest_set_target_list(TargetList *target_list);
	//!< Sets the target types that this widget can accept from drag-and-drop
	//!< @param target_list A list of droppable targets, or null for none.
	//!<
	//!< <BR>The widget must first be made into a drag destination with drag_dest_set().

//! @}
//! @name Source Drag-and-Drop Methods (from gtkdnd.h)
//! @{

	DragContext* drag_source_begin(const TargetList& targets, Gdk::DragActionField actions, int button, const Gdk::Event& event);
	//!< Initiates a drag on the source side. 
	//!< @param targets The targets (data formats) in which the source can provide the data.
	//!< @param actions A bitmask of the allowed drag actions for this drag.
	//!< @param button The button the user clicked to start the drag.
	//!< @param event The event that triggered the start of the drag.
	//!< @return The context for this drag.
	//!<	
	//!< <BR>The method only needs to be used when the application is starting drags itself, 
	//!< and is not needed when drag_source_set() is used.

	void drag_source_set(Gdk::ModifierTypeField start_button_mask, const TargetEntry& target, Gdk::DragActionField actions);
	//!< Sets up the widget so that GTK+ will start a drag operation when the user
	//!< clicks and drags on the widget. 
	//!< @param start_button_mask The bitmask of buttons that can start the drag. 
	//!< @param target The TargetEntry for the target the drag will support.
	//!< @param actions The bitmask of possible actions for a drag from this widget.	
	
	void drag_source_set(Gdk::ModifierTypeField start_button_mask, const std::vector<TargetEntry>& targets, Gdk::DragActionField actions);
	//!< Sets up the widget so that GTK+ will start a drag operation when the user
	//!< clicks and drags on the widget. 
	//!< @param start_button_mask The bitmask of buttons that can start the drag. 
	//!< @param targets A vector of TargetEntry for the targets the drag will support. 
	//!< @param actions The bitmask of possible actions for a drag from this widget.	

	void drag_source_unset();
	//!< Undoes the effects of drag_source_set().

	void drag_source_set_icon(Gdk::Colormap *colormap, Gdk::Pixmap *pixmap, Gdk::Bitmap *mask);
	//!< Sets the icon that will be used for drags from the widget from a pixmap and mask.
	//!< @param colormap The colormap of the icon.
	//!< @param pixmap The image data for the icon.
	//!< @param mask The transparency mask for an image.
	//!<
	//!< <BR>GTK+ retains references for the arguments, and will release them when they are
	//!< no longer needed. Use drag_source_set_icon_pixbuf() instead.

	void drag_source_set_icon_pixbuf(Gdk::Pixbuf& pixbuf);
	//!< Sets the icon that will be used for drags from the widget from a Gdk::Pixbuf.
	//!< @param pixbuf The Gdk::Pixbuf for the drag icon.
	//!<
	//!< <BR>GTK+ retains references for pixbuf, and will release it when it is no longer needed.

	void drag_source_set_icon_stock(const char *stock_id);
	//!< Sets the icon that will be used for drags from the widget to a stock icon.
	//!< @param stock_id The ID of the stock icon to use.

	bool drag_check_threshold(int start_x, int start_y, int current_x, int current_y);
	//!< Checks to see if a mouse drag starting at (start_x, start_y) and ending at
	//!< (current_x, current_y) has passed the GTK+ drag threshhold, and thus should
	//!< trigger the beginning of a drag-and-drop operation.
	//!< @param start_x The X coordinate of start of drag.
	//!< @param start_y The Y coordinate of start of drag.
	//!< @param current_x The current X coordinate.
	//!< @param current_y The current Y coordinate.
	//!< @return <EM>true</EM> if the drag threshold has been passed.
	
//! @}
//! @name Property Proxies
//! @{

	const NamePropertyProxy prop_name()
	{
		return NamePropertyProxy(this, &name_property);
	}
	//!< The name of the widget (String : Read / Write).

	const ParentPropertyProxy prop_parent()
	{
		return ParentPropertyProxy(this, &parent_property);
	}
	//!< The parent widget of this widget. Must be a Container widget (Container* : Read / Write).

	const WidthRequestPropertyProxy prop_width_request()
	{
		return WidthRequestPropertyProxy(this, &width_request_property);
	}
	//!< Override for width request of the widget, or -1 if the natural request
	//!< should be used (int : Read / Write).

	const HeightRequestPropertyProxy prop_height_request()
	{
		return HeightRequestPropertyProxy(this, &height_request_property);
	}
	//!< Override for height request of the widget, or -1 if the natural request 
	//!< should be used (int : Read / Write).

	const VisiblePropertyProxy prop_visible()
	{
		return VisiblePropertyProxy(this, &visible_property);
	}
	//!< Whether the widget is visible (bool : Read / Write).

	const SensitivePropertyProxy prop_sensitive()
	{
		return SensitivePropertyProxy(this, &sensitive_property);
	}
	//!< Whether the widget responds to input (bool : Read / Write).

	const AppPaintablePropertyProxy prop_app_paintable()
	{
		return AppPaintablePropertyProxy(this, &app_paintable_property);
	}
	//!< Whether the application will paint directly on the widget (bool : Read / Write).

	const CanFocusPropertyProxy prop_can_focus()
	{
		return CanFocusPropertyProxy(this, &can_focus_property);
	}
	//!< Whether the widget can accept the input focus (bool : Read / Write).

	const HasFocusPropertyProxy prop_has_focus()
	{
		return HasFocusPropertyProxy(this, &has_focus_property);
	}
	//!< Whether the widget has the input focus (bool : Read / Write).

	const IsFocusPropertyProxy prop_is_focus()
	{
		return IsFocusPropertyProxy(this, &is_focus_property);
	}
	//!< Whether the widget is the focus widget within the toplevel (bool : Read / Write).

	const CanDefaultPropertyProxy prop_can_default()
	{
		return CanDefaultPropertyProxy(this, &can_default_property);
	}
	//!< Whether the widget can be the default widget (bool : Read / Write).

	const HasDefaultPropertyProxy prop_has_default()
	{
		return HasDefaultPropertyProxy(this, &has_default_property);
	}
	//!< Whether the widget is the default widget (bool : Read / Write).

	const ReceivesDefaultPropertyProxy prop_receives_default()
	{
		return ReceivesDefaultPropertyProxy(this, &receives_default_property);
	}
	//!< If true, the widget will receive the default action when it is focused (bool : Read / Write).

	const CompositeChildPropertyProxy prop_composite_child()
	{
		return CompositeChildPropertyProxy(this, &composite_child_property);
	}
	//!< Whether the widget is part of a composite widget (bool : Read).

	const StylePropertyProxy prop_style()
	{
		return StylePropertyProxy(this, &style_property);
	}
	//!< The style of the widget, which contains information about how
	//!< it will look (Style* : Read / Write).

	const EventsPropertyProxy prop_events()
	{
		return EventsPropertyProxy(this, &events_property);
	}
	//!< The event mask that decides what kind of GdkEvents this widget gets
	//!< (Gdk::EventMask : Read / Write).

	const ExtensionEventsPropertyProxy prop_extension_events()
	{
		return ExtensionEventsPropertyProxy(this, &extension_events_property);
	}
	//!< The mask that decides what kind of extension events this widget gets
	//!< (Gdk::ExtensionMode : Read / Write).

//! @}
//! @name Basic Signal Proxies
//! @{

	const ShowSignalProxy sig_show()
	{
		return ShowSignalProxy(this, &show_signal);
	}
	//!< Connect to the show_signal; emitted when a widget becomes visible.

	const HideSignalProxy sig_hide()
	{
		return HideSignalProxy(this, &hide_signal);
	}
	//!< Connect to the hide_signal; emitted when a widget is hidden (invisible to the user).

	const MapSignalProxy sig_map()
	{
		return MapSignalProxy(this, &map_signal);
	}
	//!< Connect to the map_signal; emitted when a widget becomes mapped.

	const UnmapSignalProxy sig_unmap()
	{
		return UnmapSignalProxy(this, &unmap_signal);
	}
	//!< Connect to the unmap_signal; emitted when a widget becomes unmapped.

	const RealizeSignalProxy sig_realize()
	{
		return RealizeSignalProxy(this, &realize_signal);
	}
	//!< Connect to the realize_signal; emitted when a widget is realized.

	const UnrealizeSignalProxy sig_unrealize()
	{
		return UnrealizeSignalProxy(this, &unrealize_signal);
	}
	//!< Connect to the unrealize_signal; emitted when a widget is unrealized.

	const SizeRequestSignalProxy sig_size_request()
	{
		return SizeRequestSignalProxy(this, &size_request_signal);
	}
	//!< Connect to the size_request_signal; emitted to obtain the preferred size of a widget.

	const SizeAllocateSignalProxy sig_size_allocate()
	{
		return SizeAllocateSignalProxy(this, &size_allocate_signal);
	}
	//!< Connect to the size_allocate_signal; emitted when a child widget is allocated a size and position.

	const StateChangedSignalProxy sig_state_changed()
	{
		return StateChangedSignalProxy(this, &state_changed_signal);
	}
	//!< Connect to the state_changed_signal; emitted when the widget state changes.

	const ParentSetSignalProxy sig_parent_set()
	{
		return ParentSetSignalProxy(this, &parent_set_signal);
	}
	//!< Connect to the parent_set_signal; emitted when the parent container of the widget is set.

	const HierarchyChangedSignalProxy sig_hierarchy_changed()
	{
		return HierarchyChangedSignalProxy(this, &hierarchy_changed_signal);
	}
	//!< Connect to the hierarchy_changed_signal; emitted when there is a change 
	//!< in the hierarchy to which the widget belongs. More precisely, when its
	//!< toplevel ancestor changes.

	const StyleSetSignalProxy sig_style_set()
	{
		return StyleSetSignalProxy(this, &style_set_signal);
	}
	//!< Connect to the style_set_signal; emitted when the widget style is changed.

	const DirectionChangedSignalProxy sig_direction_changed()
	{
		return DirectionChangedSignalProxy(this, &direction_changed_signal);
	}
	//!< Connect to the direction_changed_signal; emitted when the reading direction
	//!< on the widget is changed.

	const GrabNotifySignalProxy sig_grab_notify()
	{
		return GrabNotifySignalProxy(this, &grab_notify_signal);
	}
	//!< Connect to the grab_notify_signal; emitted to notify the widget whether it is
	//!< the current grabbed widget in an application.

	const ChildNotifySignalProxy sig_child_notify()
	{
		return ChildNotifySignalProxy(this, &child_notify_signal);
	}
	//!< Connect to the child_notify_signal; emitted when a child widget property is changed.

	const MnemonicActivateSignalProxy sig_mnemonic_activate()
	{
		return MnemonicActivateSignalProxy(this, &mnemonic_activate_signal);
	}
	//!< Connect to the mnemonic_activate_signal; emitted to activate the widget 
	//!< when the mnemonic key it's associated with is pressed.

	const GrabFocusSignalProxy sig_grab_focus()
	{
		return GrabFocusSignalProxy(this, &grab_focus_signal);
	}
	//!< Connect to the grab_focus_signal; emitted when the widget receives
	//!< the keyboard focus for the Window it's inside. 	

	const FocusSignalProxy sig_focus()
	{
		return FocusSignalProxy(this, &focus_signal);
	}
	//!< Connect to the focus_signal; emitted when on a child widget when
	//!< it receives the focus (see child_focus()).

	const ScreenChangedSignalProxy sig_screen_changed()
	{
		return ScreenChangedSignalProxy(this, &screen_changed_signal);
	}
	//!< Connect to the screen_changed_signal; emitted when the Gdk::Screen on which
	//!< the widget is displayed is changed

//! @}
//! @name Selection Signal Proxies
//! @{
	
	const SelectionGetSignalProxy sig_selection_get()
	{
		return SelectionGetSignalProxy(this, &selection_get_signal);
	}
	//!< Connect to the selection_get_signal; emitted when the selection data is requested,
	//!< if this widget is the selection owner.

	const SelectionReceivedSignalProxy sig_selection_received()
	{
		return SelectionReceivedSignalProxy(this, &selection_received_signal);
	}
	//!< Connect to the selection_received_signal; emitted to notify the widget that the
	//!< requested selection data has been converted and provided by the selection owner.

//! @}
//! @name Source-side Drag Signal Proxies
//! @{
	
	const DragBeginSignalProxy sig_drag_begin()
	{
		return DragBeginSignalProxy(this, &drag_begin_signal);
	}
	//!< Connect to the drag_begin_signal; emitted to notify the widget that a
	//!< drag-and-drop event has started.

	const DragEndSignalProxy sig_drag_end()
	{
		return DragEndSignalProxy(this, &drag_end_signal);
	}
	//!< Connect to the drag_end_signal; emitted to notify the widget that a
	//!< drag-and-drop event has ended.

	const DragDataGetSignalProxy sig_drag_data_get()
	{
		return DragDataGetSignalProxy(this, &drag_data_get_signal);
	}
	//!< Connect to the drag_data_get_signal; emitted after a valid drop to request
	//!< the data of the first target supported by the destination widget.

	const DragDataDeleteSignalProxy sig_drag_data_delete()
	{
		return DragDataDeleteSignalProxy(this, &drag_data_delete_signal);
	}
	//!< Connect to the drag_data_delete_signal; emitted after a successful drop to
	//!< indicate that the data can be deleted.

//! @}
//! @name Target-side Drag Signal Proxies
//! @{
	
	const DragLeaveSignalProxy sig_drag_leave()
	{
		return DragLeaveSignalProxy(this, &drag_leave_signal);
	}
	//!< Connect to the drag_leave_signal; emitted whenever a drag-and-drop action leaves the widget.

	const DragMotionSignalProxy sig_drag_motion()
	{
		return DragMotionSignalProxy(this, &drag_motion_signal);
	}
	//!< Connect to the drag_motion_signal; emitted when the mouse passes over the widget
	//!< to verifiy whether it can accept a drop.

	const DragDropSignalProxy sig_drag_drop()
	{
		return DragDropSignalProxy(this, &drag_drop_signal);
	}
	//!< Connect to the drag_drop_signal; emitted to notify the widget that a drop has occurred. 

	const DragDataReceivedSignalProxy sig_drag_data_received()
	{
		return DragDataReceivedSignalProxy(this, &drag_data_received_signal);
	}
	//!< Connect to the drag_data_received_signal; emitted to notify the widget 
	//!< when the data from a drop is received.

//! @}
//! @name GDK Event Signal Proxies
//! @{
	
	const EventSignalProxy sig_event()
	{
		return EventSignalProxy(this, &event_signal);
	}
	//!< Connect to the event_signal; emitted when any GDK event occurs.

	const ButtonPressEventSignalProxy sig_button_press_event()
	{
		return ButtonPressEventSignalProxy(this, &button_press_event_signal);
	}
	//!< Connect to the button_press_event_signal; emitted when a mouse button has been pressed.

	const ButtonReleaseEventSignalProxy sig_button_release_event()
	{
		return ButtonReleaseEventSignalProxy(this, &button_release_event_signal);
	}
	//!< Connect to the button_release_event_signal; emitted when a mouse button has been released.

	const ScrollEventSignalProxy sig_scroll_event()
	{
		return ScrollEventSignalProxy(this, &scroll_event_signal);
	}
	//!< Connect to the scroll_event_signal; emitted when a mouse wheel is scrolled either up or down.

	const MotionNotifyEventSignalProxy sig_motion_notify_event()
	{
		return MotionNotifyEventSignalProxy(this, &motion_notify_event_signal);
	}
	//!< Connect to the motion_notify_event_signal; emitted when the mouse is moved.

	const DestroyEventSignalProxy sig_destroy_event()
	{
		return DestroyEventSignalProxy(this, &destroy_event_signal);
	}
	//!< Connect to the destroy_event_signal; emitted when the widget has been destroyed.

	const ExposeEventSignalProxy sig_expose_event()
	{
		return ExposeEventSignalProxy(this, &expose_event_signal);
	}
	//!< Connect to the expose_event_signal; emitted when all or part of the widget
	//!< has become visible and needs to be redrawn.

	const KeyPressEventSignalProxy sig_key_press_event()
	{
		return KeyPressEventSignalProxy(this, &key_press_event_signal);
	}
	//!< Connect to the key_press_event_signal; emitted when a key is pressed.

	const KeyReleaseEventSignalProxy sig_key_release_event()
	{
		return KeyReleaseEventSignalProxy(this, &key_release_event_signal);
	}
	//!< Connect to the key_release_event_signal; emitted when a key is released.

	const EnterNotifyEventSignalProxy sig_enter_notify_event()
	{
		return EnterNotifyEventSignalProxy(this, &enter_notify_event_signal);
	}
	//!< Connect to the enter_notify_event_signal; emitted when the widget is entered.

	const LeaveNotifyEventSignalProxy sig_leave_notify_event()
	{
		return LeaveNotifyEventSignalProxy(this, &leave_notify_event_signal);
	}
	//!< Connect to the leave_notify_event_signal; emitted when then widget is exited.

	const ConfigureEventSignalProxy sig_configure_event()
	{
		return ConfigureEventSignalProxy(this, &configure_event_signal);
	}
	//!< Connect to the configure_event_signal; emitted when the size, position or
	//!< stacking order of the widget is changed.

	const FocusInEventSignalProxy sig_focus_in_event()
	{
		return FocusInEventSignalProxy(this, &focus_in_event_signal);
	}
	//!< Connect to the focus_in_event_signal; emitted when the widget gains the keyboard focus
	//!< (the focus widget gets keyboard events).

	const FocusOutEventSignalProxy sig_focus_out_event()
	{
		return FocusOutEventSignalProxy(this, &focus_out_event_signal);
	}
	//!< Connect to the focus_out_event_signal; emitted when the widget looses the keyboard focus.

	const MapEventSignalProxy sig_map_event()
	{
		return MapEventSignalProxy(this, &map_event_signal);
	}
	//!< Connect to the map_event_signal; emitted when the widget has been mapped 
	//!< (visible on the screen).

	const UnmapEventSignalProxy sig_unmap_event()
	{
		return UnmapEventSignalProxy(this, &unmap_event_signal);
	}
	//!< Connect to the unmap_event_signal; emitted when the widget has been mapped
	//!< (no longer visible on the screen).

	const PropertyNotifyEventSignalProxy sig_property_notify_event()
	{
		return PropertyNotifyEventSignalProxy(this, &property_notify_event_signal);
	}
	//!< Connect to the property_notify_event_signal; emitted when a property on the widget
	//!< has been changed or deleted.

	const SelectionClearEventSignalProxy sig_selection_clear_event()
	{
		return SelectionClearEventSignalProxy(this, &selection_clear_event_signal);
	}
	//!< Connect to the selection_clear_event_signal; emitted when an application has
	//!< lost ownership of a selection.

	const SelectionRequestEventSignalProxy sig_selection_request_event()
	{
		return SelectionRequestEventSignalProxy(this, &selection_request_event_signal);
	}
	//!< Connect to the selection_request_event_signal; emitted when another application
	//!< has requested a selection.

	const SelectionNotifyEventSignalProxy sig_selection_notify_event()
	{
		return SelectionNotifyEventSignalProxy(this, &selection_notify_event_signal);
	}
	//!< Connect to the selection_notify_event_signal; emitted when a selection has been received.

	const ProximityInEventSignalProxy sig_proximity_in_event()
	{
		return ProximityInEventSignalProxy(this, &proximity_in_event_signal);
	}
	//!< Connect to the proximity_in_event_signal; emitted when an input device has moved
	//!< into contact with a sensing surface (such as a touchscreen or graphics tablet).

	const ProximityOutEventSignalProxy sig_proximity_out_event()
	{
		return ProximityOutEventSignalProxy(this, &proximity_out_event_signal);
	}
	//!< Connect to the proximity_out_event_signal; emitted when an input device
	//!< has moved out of contact with a sensing surface.

	const VisibilityNotifyEventSignalProxy sig_visibility_notify_event()
	{
		return VisibilityNotifyEventSignalProxy(this, &visibility_notify_event_signal);
	}
	//!< Connect to the visibility_notify_event_signal; emitted when the widget's visibility
	//!< status has changed (either fully obscured, partially obscured or unobscured).

	const ClientEventSignalProxy sig_client_event()
	{
		return ClientEventSignalProxy(this, &client_event_signal);
	}
	//!< Connect to the client_event_signal; emitted when a message has been received
	//!< from another application.

	const NoExposeEventSignalProxy sig_no_expose_event()
	{
		return NoExposeEventSignalProxy(this, &no_expose_event_signal);
	}
	//!< Connect to the no_expose_event_signal; emitted when all or part of the widget
	//!< has become visible, but no expose event was generated.

	const WindowStateEventSignalProxy sig_window_state_event()
	{
		return WindowStateEventSignalProxy(this, &window_state_event_signal);
	}
	//!< Connect to the window_state_event_signal; emitted when the state of a toplevel
	//!< window changes (either not shown, minimized, maximized, sticky or fullscreen).

//! @}
};

} // namespace Gtk

} // namespace Inti

#endif // INTI_GTK_WIDGET_H

