Main Page - Header
Author: The Inti Development Team

Reference Manual

Main Page | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Namespace Members | Compound Members | File Members

# stock.h

Go to the documentation of this file.

    00001 /*  Inti: Integrated Foundation Classes
    00002  *  Copyright (C) 2002 The Inti Development Team.
    00003  *
    00004  *  This program is free software; you can redistribute it and/or modify
    00005  *  it under the terms of the GNU General Public License as published by
    00006  *  the Free Software Foundation; either version 2 of the License, or
    00007  *  (at your option) any later version.
    00008  *
    00009  *  This program is distributed in the hope that it will be useful,
    00010  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
    00011  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    00012  *  GNU Library General Public License for more details.
    00013  *
    00014  *  You should have received a copy of the GNU Library General Public License
    00015  *  along with this program; if not, write to the Free Software
    00016  *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
    00017  */
    00018
    00024
    00025 #ifndef INTI_GTK_STOCK_H
    00026 #define INTI_GTK_STOCK_H
    00027
    00028 #ifndef INTI_UTF_STRING_H
    00029 #include <inti/utf-string.h>
    00030 #endif
    00031
    00032 #ifndef INTI_GDK_TYPES_H
    00033 #include <inti/gdk/types.h>
    00034 #endif
    00035
    00036 #ifndef __GTK_STOCK_H__
    00037 #include <gtk/gtkstock.h>
    00038 #endif
    00039
    00040 #ifndef _CPP_VECTOR
    00041 #include <vector>
    00042 #endif
    00043
    00044 namespace Inti {
    00045
    00046 namespace Gtk {
    00047
    00048 class AccelKey;
    00049
    00064
    00065 class StockItem
    00066 {
    00067         GtkStockItem item_;
    00068
    00069 public:
    00072
    00073         StockItem();
    00075
    00079
    00080         GtkStockItem* gtk_stock_item() const { return const_cast<GtkStockItem*>(&item_); }
    00082
    00083         const char* stock_id() const;
    00085
    00086         const char* label() const;
    00088
    00089         Gdk::ModifierTypeField modifier() const;
    00091
    00092         unsigned int keyval() const;
    00094
    00095         const char* translation_domain() const;
    00097
    00098         AccelKey accel_key() const;
    00100
    00102 };
    00103
    00108
    00109 class Stock
    00110 {
    00111 public:
    00114
    00115         static void add(const char *stock_id, const char *label);
    00122
    00123         static void add(const char *stock_id, const char *label, Gdk::ModifierTypeField modifier, unsigned int key);
    00132
    00133         static void add(const char *stock_id, const char *label, Gdk::ModifierTypeField modifier, unsigned int key, const char *domain);
    00143
    00144         static bool lookup(const char *stock_id, StockItem& item);
    00149
    00150         static std::vector<String> list_ids();
    00153
    00155 };
    00156
    00157 } // namespace Gtk
    00158
    00159 } // namespace Inti
    00160
    00161 #endif // INTI_GTK_STOCK_H
    00162

Main Page - Footer