00001
00002
00003 #ifndef _LIBGNOMEUIMM_FILE_ENTRY_H
00004 #define _LIBGNOMEUIMM_FILE_ENTRY_H
00005
00006
00007 #include <glibmm.h>
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031 #include <gtkmm/box.h>
00032 #include <gtkmm/editable.h>
00033
00034
00035
00036 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00037 typedef struct _GnomeFileEntry GnomeFileEntry;
00038 typedef struct _GnomeFileEntryClass GnomeFileEntryClass;
00039 #endif
00040
00041
00042 namespace Gnome
00043 {
00044
00045 namespace UI
00046 { class FileEntry_Class; }
00047
00048 }
00049 namespace Gnome
00050 {
00051
00052 namespace UI
00053 {
00054
00055
00056 class FileEntry
00057 : public Gtk::VBox,
00058 public Gtk::Editable
00059 {
00060 public:
00061 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00062 typedef FileEntry CppObjectType;
00063 typedef FileEntry_Class CppClassType;
00064 typedef GnomeFileEntry BaseObjectType;
00065 typedef GnomeFileEntryClass BaseClassType;
00066 #endif
00067
00068 virtual ~FileEntry();
00069
00070 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00071
00072 private:
00073 friend class FileEntry_Class;
00074 static CppClassType fileentry_class_;
00075
00076
00077 FileEntry(const FileEntry&);
00078 FileEntry& operator=(const FileEntry&);
00079
00080 protected:
00081 explicit FileEntry(const Glib::ConstructParams& construct_params);
00082 explicit FileEntry(GnomeFileEntry* castitem);
00083
00084 #endif
00085
00086 public:
00087 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00088 static GType get_type() G_GNUC_CONST;
00089 static GType get_base_type() G_GNUC_CONST;
00090 #endif
00091
00093 GnomeFileEntry* gobj() { return reinterpret_cast<GnomeFileEntry*>(gobject_); }
00094
00096 const GnomeFileEntry* gobj() const { return reinterpret_cast<GnomeFileEntry*>(gobject_); }
00097
00098
00099 public:
00100
00101
00102 protected:
00103
00104
00105
00106 virtual void on_browse_clicked();
00107 virtual void on_activate();
00108
00109
00110 private:
00111
00112
00113 public:
00114 FileEntry();
00115
00116 FileEntry(const Glib::ustring& history_id, const Glib::ustring& browse_dialog_title);
00117
00118
00119 Gtk::Widget* gnome_entry();
00120
00121 Gtk::Widget* gtk_entry();
00122
00123
00124 void set_title (const Glib::ustring& browse_dialog_title);
00125
00126 void set_default_path(const Glib::ustring& path);
00127
00128 void set_directory_entry(bool directory_entry = true);
00129
00130 bool get_directory_entry() const;
00131
00132 Glib::ustring get_full_path(bool file_must_exist) const;
00133
00134 void set_filename(const Glib::ustring& filename);
00135
00136 void set_modal(bool is_modal = true);
00137
00138 bool get_modal() const;
00139
00140
00141 Glib::SignalProxy0< void > signal_browse_clicked();
00142 ;
00143
00144
00145 Glib::SignalProxy0< void > signal_activate();
00146 ;
00147
00148
00149 };
00150
00151 }
00152 }
00153
00154
00155 namespace Glib
00156 {
00162 Gnome::UI::FileEntry* wrap(GnomeFileEntry* object, bool take_copy = false);
00163 }
00164
00165
00166 #endif
00167