2 * This file is part of duit.
4 * duit is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU Lesser General Public License as published by
6 * the Free Software Foundation; either version 2.1 of the License, or
7 * (at your option) any later version.
9 * duit is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public License
15 * along with duit; if not, write to the Free Software
16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19 // generated automatically - do not change
20 // find conversion definition on APILookup.txt
21 // implement new conversion functionalities on the wrap.utils pakage
24 * Conversion parameters:
25 * inFile = GtkCellEditable.html
27 * outFile = CellEditable
28 * strct = GtkCellEditable
39 * - gtk_cell_editable_
47 * - GdkEvent* -> Event
51 module gtk
.CellEditable
;
53 private import gtk
.gtktypes
;
55 private import lib
.gtk
;
57 private import gdk
.Event
;
61 * The GtkCellEditable interface must be implemented for widgets
62 * to be usable when editing the contents of a GtkTreeView cell.
64 public class CellEditable
67 /** the main Gtk struct */
68 protected GtkCellEditable
* gtkCellEditable
;
71 public GtkCellEditable
* getCellEditableStruct()
73 return gtkCellEditable
;
77 /** the main Gtk struct as a void* */
78 protected void* getStruct()
80 return cast(void*)gtkCellEditable
;
84 * Sets our main struct and passes it to the parent class
86 public this (GtkCellEditable
* gtkCellEditable
)
88 this.gtkCellEditable
= gtkCellEditable
;
94 // imports for the signal processing
95 private import gobject
.Signals
;
96 private import gdk
.gdktypes
;
97 int[char[]] connectedSignals
;
99 void delegate(CellEditable
)[] onEditingDoneListeners
;
100 void addOnEditingDone(void delegate(CellEditable
) dlg
)
102 if ( !("editing-done" in connectedSignals
) )
107 cast(GCallback
)&callBackEditingDone
,
110 cast(ConnectFlags
)0);
111 connectedSignals
["editing-done"] = 1;
113 onEditingDoneListeners
~= dlg
;
115 extern(C
) static void callBackEditingDone(GtkCellEditable
* celleditableStruct
, CellEditable cellEditable
)
117 bit consumed
= false;
119 foreach ( void delegate(CellEditable
) dlg
; cellEditable
.onEditingDoneListeners
)
127 void delegate(CellEditable
)[] onRemoveWidgetListeners
;
128 void addOnRemoveWidget(void delegate(CellEditable
) dlg
)
130 if ( !("remove-widget" in connectedSignals
) )
135 cast(GCallback
)&callBackRemoveWidget
,
138 cast(ConnectFlags
)0);
139 connectedSignals
["remove-widget"] = 1;
141 onRemoveWidgetListeners
~= dlg
;
143 extern(C
) static void callBackRemoveWidget(GtkCellEditable
* celleditableStruct
, CellEditable cellEditable
)
145 bit consumed
= false;
147 foreach ( void delegate(CellEditable
) dlg
; cellEditable
.onRemoveWidgetListeners
)
159 * Begins editing on a cell_editable. event is the GdkEvent that began the
160 * editing process. It may be NULL, in the instance that editing was initiated
161 * through programatic means.
165 * A GdkEvent, or NULL
167 public void startEditing(Event event
)
169 // void gtk_cell_editable_start_editing (GtkCellEditable *cell_editable, GdkEvent *event);
170 gtk_cell_editable_start_editing(gtkCellEditable
, (event
is null) ?
null : event
.getEventStruct());
174 * Emits the "editing_done" signal. This signal is a sign for the cell renderer
175 * to update its value from the cell.
179 public void editingDone()
181 // void gtk_cell_editable_editing_done (GtkCellEditable *cell_editable);
182 gtk_cell_editable_editing_done(gtkCellEditable
);
186 * Emits the "remove_widget" signal. This signal is meant to indicate that the
187 * cell is finished editing, and the widget may now be destroyed.
191 * The "editing-done" signal
192 * void user_function (GtkCellEditable *celleditable,
193 * gpointer user_data) : Run last
195 * the object which received the signal.
197 * user data set when the signal handler was connected.
199 public void removeWidget()
201 // void gtk_cell_editable_remove_widget (GtkCellEditable *cell_editable);
202 gtk_cell_editable_remove_widget(gtkCellEditable
);