// -*- c++ -*-
// Generated by gtkmmproc -- DO NOT MODIFY!
#ifndef _LIBGNOMEUIMM_DATEEDIT_H
#define _LIBGNOMEUIMM_DATEEDIT_H


#include <glibmm.h>

/* $Id: dateedit.hg,v 1.13 2003/05/29 17:13:42 murrayc Exp $ */

/* dateedit.hg
 * 
 * Copyright (C) 1999 The Gtk-- Development Team
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 *
 * This library 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
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free
 * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 */

#include <time.h>
#include <gtkmm/box.h>
#include <libgnomeui/gnometypebuiltins.h>
#include <libgnomeui/gnome-dateedit.h>


#ifndef DOXYGEN_SHOULD_SKIP_THIS
typedef struct _GnomeDateEdit GnomeDateEdit;
typedef struct _GnomeDateEditClass GnomeDateEditClass;
#endif /* DOXYGEN_SHOULD_SKIP_THIS */


namespace Gnome
{

namespace UI
{ class DateEdit_Class; } // namespace UI

} // namespace Gnome
namespace Gnome
{

namespace UI
{

/** @addtogroup libgnomeuimmEnums Enums and Flags */

/**
 * @ingroup libgnomeuimmEnums
 * @par Bitwise operators:
 * <tt>%DateEditFlags operator|(DateEditFlags, DateEditFlags)</tt><br>
 * <tt>%DateEditFlags operator&(DateEditFlags, DateEditFlags)</tt><br>
 * <tt>%DateEditFlags operator^(DateEditFlags, DateEditFlags)</tt><br>
 * <tt>%DateEditFlags operator~(DateEditFlags)</tt><br>
 * <tt>%DateEditFlags& operator|=(DateEditFlags&, DateEditFlags)</tt><br>
 * <tt>%DateEditFlags& operator&=(DateEditFlags&, DateEditFlags)</tt><br>
 * <tt>%DateEditFlags& operator^=(DateEditFlags&, DateEditFlags)</tt><br>
 */
enum DateEditFlags
{
  DATE_EDIT_SHOW_TIME = 1 << 0,
  DATE_EDIT_24_HR = 1 << 1,
  DATE_EDIT_WEEK_STARTS_ON_MONDAY = 1 << 2
};

/** @ingroup libgnomeuimmEnums */
inline DateEditFlags operator|(DateEditFlags lhs, DateEditFlags rhs)
  { return static_cast<DateEditFlags>(static_cast<unsigned>(lhs) | static_cast<unsigned>(rhs)); }

/** @ingroup libgnomeuimmEnums */
inline DateEditFlags operator&(DateEditFlags lhs, DateEditFlags rhs)
  { return static_cast<DateEditFlags>(static_cast<unsigned>(lhs) & static_cast<unsigned>(rhs)); }

/** @ingroup libgnomeuimmEnums */
inline DateEditFlags operator^(DateEditFlags lhs, DateEditFlags rhs)
  { return static_cast<DateEditFlags>(static_cast<unsigned>(lhs) ^ static_cast<unsigned>(rhs)); }

/** @ingroup libgnomeuimmEnums */
inline DateEditFlags operator~(DateEditFlags flags)
  { return static_cast<DateEditFlags>(~static_cast<unsigned>(flags)); }

/** @ingroup libgnomeuimmEnums */
inline DateEditFlags& operator|=(DateEditFlags& lhs, DateEditFlags rhs)
  { return (lhs = static_cast<DateEditFlags>(static_cast<unsigned>(lhs) | static_cast<unsigned>(rhs))); }

/** @ingroup libgnomeuimmEnums */
inline DateEditFlags& operator&=(DateEditFlags& lhs, DateEditFlags rhs)
  { return (lhs = static_cast<DateEditFlags>(static_cast<unsigned>(lhs) & static_cast<unsigned>(rhs))); }

/** @ingroup libgnomeuimmEnums */
inline DateEditFlags& operator^=(DateEditFlags& lhs, DateEditFlags rhs)
  { return (lhs = static_cast<DateEditFlags>(static_cast<unsigned>(lhs) ^ static_cast<unsigned>(rhs))); }

} // namespace UI

} // namespace Gnome


#ifndef DOXYGEN_SHOULD_SKIP_THIS
namespace Glib
{

template <>
class Value<Gnome::UI::DateEditFlags> : public Glib::Value_Flags<Gnome::UI::DateEditFlags>
{
public:
  static GType value_type() G_GNUC_CONST;
};

} // namespace Glib
#endif /* DOXYGEN_SHOULD_SKIP_THIS */


namespace Gnome
{

namespace UI
{


/** Date and time entry widget.
 * This widget provides a way to enter dates and
 * times with a helper calendar to let the user select the date.
 */

class DateEdit : public Gtk::HBox
{
  public:
#ifndef DOXYGEN_SHOULD_SKIP_THIS
  typedef DateEdit CppObjectType;
  typedef DateEdit_Class CppClassType;
  typedef GnomeDateEdit BaseObjectType;
  typedef GnomeDateEditClass BaseClassType;
#endif /* DOXYGEN_SHOULD_SKIP_THIS */

  virtual ~DateEdit();

#ifndef DOXYGEN_SHOULD_SKIP_THIS

private:
  friend class DateEdit_Class;
  static CppClassType dateedit_class_;

  // noncopyable
  DateEdit(const DateEdit&);
  DateEdit& operator=(const DateEdit&);

protected:
  explicit DateEdit(const Glib::ConstructParams& construct_params);
  explicit DateEdit(GnomeDateEdit* castitem);

#endif /* DOXYGEN_SHOULD_SKIP_THIS */

public:
#ifndef DOXYGEN_SHOULD_SKIP_THIS
  static GType get_type()      G_GNUC_CONST;


  static GType get_base_type() G_GNUC_CONST;
#endif

  ///Provides access to the underlying C GtkObject.
  GnomeDateEdit*       gobj()       { return reinterpret_cast<GnomeDateEdit*>(gobject_); }

  ///Provides access to the underlying C GtkObject.
  const GnomeDateEdit* gobj() const { return reinterpret_cast<GnomeDateEdit*>(gobject_); }


public:
  //C++ methods used to invoke GTK+ virtual functions:
#ifdef GLIBMM_VFUNCS_ENABLED
#endif //GLIBMM_VFUNCS_ENABLED

protected:
  //GTK+ Virtual Functions (override these to change behaviour):
#ifdef GLIBMM_VFUNCS_ENABLED
#endif //GLIBMM_VFUNCS_ENABLED

  //Default Signal Handlers::
#ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
  virtual void on_date_changed();
  virtual void on_time_changed();
#endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED


private:

  
public:
  DateEdit(time_t, bool show_time = true, bool use_24_format = true);
  DateEdit(time_t the_time = 0, DateEditFlags flags = DATE_EDIT_SHOW_TIME);

  
  void set_time(time_t the_time);
  
  time_t get_time() const;
  
  void set_popup_range(int low_hour, int up_hour);
  
  void set_flags(DateEditFlags flags);
  
  DateEditFlags get_flags() const;
  
  time_t get_initial_time() const;

  
  /**
   * @par Prototype:
   * <tt>void on_my_%date_changed()</tt>
   */

  Glib::SignalProxy0< void > signal_date_changed();

  
  /**
   * @par Prototype:
   * <tt>void on_my_%time_changed()</tt>
   */

  Glib::SignalProxy0< void > signal_time_changed();


  #ifdef GLIBMM_PROPERTIES_ENABLED
/** 
   *
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
   * the value of the property changes.
   */
  Glib::PropertyProxy<gulong> property_time() ;
#endif //#GLIBMM_PROPERTIES_ENABLED

#ifdef GLIBMM_PROPERTIES_ENABLED
/** 
   *
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
   * the value of the property changes.
   */
  Glib::PropertyProxy_ReadOnly<gulong> property_time() const;
#endif //#GLIBMM_PROPERTIES_ENABLED

  #ifdef GLIBMM_PROPERTIES_ENABLED
/** 
   *
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
   * the value of the property changes.
   */
  Glib::PropertyProxy<DateEditFlags> property_dateedit_flags() ;
#endif //#GLIBMM_PROPERTIES_ENABLED

#ifdef GLIBMM_PROPERTIES_ENABLED
/** 
   *
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
   * the value of the property changes.
   */
  Glib::PropertyProxy_ReadOnly<DateEditFlags> property_dateedit_flags() const;
#endif //#GLIBMM_PROPERTIES_ENABLED

  #ifdef GLIBMM_PROPERTIES_ENABLED
/** 
   *
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
   * the value of the property changes.
   */
  Glib::PropertyProxy<int> property_lower_hour() ;
#endif //#GLIBMM_PROPERTIES_ENABLED

#ifdef GLIBMM_PROPERTIES_ENABLED
/** 
   *
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
   * the value of the property changes.
   */
  Glib::PropertyProxy_ReadOnly<int> property_lower_hour() const;
#endif //#GLIBMM_PROPERTIES_ENABLED

  #ifdef GLIBMM_PROPERTIES_ENABLED
/** 
   *
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
   * the value of the property changes.
   */
  Glib::PropertyProxy<int> property_upper_hour() ;
#endif //#GLIBMM_PROPERTIES_ENABLED

#ifdef GLIBMM_PROPERTIES_ENABLED
/** 
   *
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
   * the value of the property changes.
   */
  Glib::PropertyProxy_ReadOnly<int> property_upper_hour() const;
#endif //#GLIBMM_PROPERTIES_ENABLED

  #ifdef GLIBMM_PROPERTIES_ENABLED
/** 
   *
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
   * the value of the property changes.
   */
  Glib::PropertyProxy<gulong> property_initial_time() ;
#endif //#GLIBMM_PROPERTIES_ENABLED

#ifdef GLIBMM_PROPERTIES_ENABLED
/** 
   *
   * You rarely need to use properties because there are get_ and set_ methods for almost all of them.
   * @return A PropertyProxy that allows you to get or set the property of the value, or receive notification when
   * the value of the property changes.
   */
  Glib::PropertyProxy_ReadOnly<gulong> property_initial_time() const;
#endif //#GLIBMM_PROPERTIES_ENABLED


};

} /* namespace UI */
} /* namespace Gnome */


namespace Glib
{
  /** A Glib::wrap() method for this object.
   * 
   * @param object The C instance.
   * @param take_copy False if the result should take ownership of the C instance. True if it should take a new copy or ref.
   * @result A C++ instance that wraps this C instance.
   *
   * @relates Gnome::UI::DateEdit
   */
  Gnome::UI::DateEdit* wrap(GnomeDateEdit* object, bool take_copy = false);
} //namespace Glib


#endif /* _LIBGNOMEUIMM_DATEEDIT_H */

