00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
#ifndef LIBGNOMEUIMM_ICON_H
00023
#define LIBGNOMEUIMM_ICON_H
00024
00025
#include <gtkmm/stockid.h>
00026
#include <libgnomeui/gnome-app-helper.h>
00027
00028
namespace Gnome
00029 {
00030
00031
namespace UI
00032 {
00033
00034
namespace Items
00035 {
00036
00038 class Icon
00039 {
00040
public:
00041 enum Type
00042 {
00043
NONE = GNOME_APP_PIXMAP_NONE,
00044
STOCK = GNOME_APP_PIXMAP_STOCK,
00045
DATA = GNOME_APP_PIXMAP_DATA,
00046
FILENAME = GNOME_APP_PIXMAP_FILENAME
00047 };
00048
00049
explicit Icon(
const Gtk::StockID& stock_id);
00050
Icon(Type type = NONE);
00051
~Icon();
00052
00053 Type
get_type()
const;
00054 gconstpointer get_pixmap_info()
const;
00055
00056 protected:
00057
00058 Type pixmap_type_;
00059 typedef const
char * const * const
xpmdata_t;
00060
00061
00062 gconstpointer xpm_data_;
00063 Glib::ustring stock_id_;
00064 std::string filename_;
00065 };
00066
00067 class
IconXpm : public
Icon
00068 {
00069
public:
00070
IconXpm(xpmdata_t xpm);
00071 ~
IconXpm();
00072 };
00073
00074 class IconFile :
public Icon
00075 {
00076
public:
00077
IconFile(
const std::string& file);
00078 ~
IconFile();
00079 };
00080
00081 }
00082 }
00083 }
00084
00085
00086
00087
#endif //LIBGNOMEUIMM_ICON_H