1 /* 2 * This file is part of gtkD. 3 * 4 * gtkD is free software; you can redistribute it and/or modify 5 * it under the terms of the GNU Lesser General Public License 6 * as published by the Free Software Foundation; either version 3 7 * of the License, or (at your option) any later version, with 8 * some exceptions, please read the COPYING file. 9 * 10 * gtkD is distributed in the hope that it will be useful, 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 * GNU Lesser General Public License for more details. 14 * 15 * You should have received a copy of the GNU Lesser General Public License 16 * along with gtkD; if not, write to the Free Software 17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110, USA 18 */ 19 20 // generated automatically - do not change 21 // find conversion definition on APILookup.txt 22 // implement new conversion functionalities on the wrap.utils pakage 23 24 /* 25 * Conversion parameters: 26 * inFile = GtkSourceUndoManager.html 27 * outPack = gsv 28 * outFile = SourceUndoManagerIF 29 * strct = GtkSourceUndoManager 30 * realStrct= 31 * ctorStrct= 32 * clss = SourceUndoManagerT 33 * interf = SourceUndoManagerIF 34 * class Code: No 35 * interface Code: No 36 * template for: 37 * extend = 38 * implements: 39 * prefixes: 40 * - gtk_source_undo_manager_ 41 * omit structs: 42 * omit prefixes: 43 * omit code: 44 * omit signals: 45 * imports: 46 * structWrap: 47 * module aliases: 48 * local aliases: 49 * overrides: 50 */ 51 52 module gsv.SourceUndoManagerIF; 53 54 public import gsvc.gsvtypes; 55 56 private import gsvc.gsv; 57 private import glib.ConstructionException; 58 private import gobject.ObjectG; 59 60 private import gobject.Signals; 61 public import gtkc.gdktypes; 62 63 64 65 66 67 /** 68 * The GtkSourceUndoManager interface can be implemented to provide custom 69 * undo management to a GtkSourceBuffer. Use 70 * gtk_source_buffer_set_undo_manager() to install a custom undo manager for 71 * a particular source buffer. 72 * 73 * Use gtk_source_undo_manager_can_undo_changed() and 74 * gtk_source_undo_manager_can_redo_changed() when respectively the undo state 75 * or redo state of the undo stack has changed. 76 */ 77 public interface SourceUndoManagerIF 78 { 79 80 81 public GtkSourceUndoManager* getSourceUndoManagerTStruct(); 82 83 /** the main Gtk struct as a void* */ 84 protected void* getStruct(); 85 86 87 /** 88 */ 89 90 @property void delegate(SourceUndoManagerIF)[] onCanRedoChangedListeners(); 91 /** 92 * Emitted when the ability to redo has changed. 93 * Since 2.10 94 */ 95 void addOnCanRedoChanged(void delegate(SourceUndoManagerIF) dlg, ConnectFlags connectFlags=cast(ConnectFlags)0); 96 @property void delegate(SourceUndoManagerIF)[] onCanUndoChangedListeners(); 97 /** 98 * Emitted when the ability to undo has changed. 99 * Since 2.10 100 * See Also 101 * GtkTextBuffer, GtkSourceView 102 */ 103 void addOnCanUndoChanged(void delegate(SourceUndoManagerIF) dlg, ConnectFlags connectFlags=cast(ConnectFlags)0); 104 105 /** 106 * Get whether there are undo operations available. 107 * Since 2.10 108 * Returns: TRUE if there are undo operations available, FALSE otherwise 109 */ 110 public int canUndo(); 111 112 /** 113 * Get whether there are redo operations available. 114 * Since 2.10 115 * Returns: TRUE if there are redo operations available, FALSE otherwise 116 */ 117 public int canRedo(); 118 119 /** 120 * Perform a single undo. Calling this function when there are no undo operations 121 * available is an error. Use gtk_source_undo_manager_can_undo() to find out 122 * if there are undo operations available. 123 * Since 2.10 124 */ 125 public void undo(); 126 127 /** 128 * Perform a single redo. Calling this function when there are no redo operations 129 * available is an error. Use gtk_source_undo_manager_can_redo() to find out 130 * if there are redo operations available. 131 * Since 2.10 132 */ 133 public void redo(); 134 135 /** 136 * Begin a not undoable action on the buffer. All changes between this call 137 * and the call to gtk_source_undo_manager_end_not_undoable_action() cannot 138 * be undone. This function should be re-entrant. 139 * Since 2.10 140 */ 141 public void beginNotUndoableAction(); 142 143 /** 144 * Ends a not undoable action on the buffer. 145 * Since 2.10 146 */ 147 public void endNotUndoableAction(); 148 149 /** 150 * Emits the "can-undo-changed" signal. 151 * Since 2.10 152 */ 153 public void canUndoChanged(); 154 155 /** 156 * Emits the "can-redo-changed" signal. 157 * Since 2.10 158 * Signal Details 159 * The "can-redo-changed" signal 160 * void user_function (GtkSourceUndoManager *manager, 161 * gpointer user_data) : Action 162 * Emitted when the ability to redo has changed. 163 * Since 2.10 164 */ 165 public void canRedoChanged(); 166 }