Sophie

Sophie

distrib > Mandriva > 9.1 > ppc > media > main > by-pkgid > ca81b57b553ae75608ba0fc5e7925e4e > files > 472

libgtkmm1.2-devel-1.2.10-1mdk.ppc.rpm

/* $Id: bin.gen_h,v 1.40 2001/07/15 13:33:38 murrayc Exp $ */

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

#include <gtk--/container.h>
#include <gtk/gtkbin.h>


namespace Gtk {
//: Signal Widget Container
//- Gtk_Bin is an abstract base class from which classes holding
//- one widget inside of them derive.  It provides access to methods
//- relevent to a single object like add_label, add_pixmap, etc.
class Bin : public Container {


public:
  typedef Bin          CppObjectType;
  typedef GtkBin            BaseObjectType;

public:
  //: Returns the underlaying gtk+ object.
  GtkBin* gtkobj();
  const GtkBin* gtkobj() const;

  //: Returns true if object is this type.
  static bool isA(Gtk::Object *object);

  virtual ~Bin();

private:

public:




  // get_child() is convenience function to get c++ wrapper of
  // the contained widget. It may return NULL, if such item is not
  // available or if it does not have existing C++ wrapper.
  Gtk::Widget* get_child() const;

  //: Remove the contained object
  //- Since Gtk_Bin can only hold one object it is not necessary to
  //- specify which object to remove like other containers.
  void remove();

  void add_label(const string &label,
                    gfloat x=0.0,
                    gfloat y=0.5);

  void add_pixmap(const Gdk_Pixmap &pixmap,
                    const Gdk_Bitmap &bitmap);

  void add_pixlabel(const Gdk_Pixmap &pixmap,
                    const Gdk_Bitmap &bitmap,
                    const string &label,
                    gfloat x=0.0,
                    gfloat y=0.5);

  void add_pixlabel(const string &pixfile,
                    const string &label,
                    gfloat x=0.0,
                    gfloat y=0.5);
protected:
  Bin();



protected:
  // impl functions

};


//+ PROPERTIES(Gtk_Bin)
//. name: child
//. type: Gtk_Widget*
//. get:
//. set:
//. desc:
}