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 = GLoadableIcon.html 27 * outPack = gio 28 * outFile = LoadableIconIF 29 * strct = GLoadableIcon 30 * realStrct= 31 * ctorStrct= 32 * clss = LoadableIconT 33 * interf = LoadableIconIF 34 * class Code: No 35 * interface Code: No 36 * template for: 37 * extend = 38 * implements: 39 * prefixes: 40 * - g_loadable_icon_ 41 * omit structs: 42 * omit prefixes: 43 * omit code: 44 * omit signals: 45 * imports: 46 * - glib.Str 47 * - glib.ErrorG 48 * - glib.GException 49 * - gio.AsyncResultIF 50 * - gio.Cancellable 51 * - gio.InputStream 52 * structWrap: 53 * - GAsyncResult* -> AsyncResultIF 54 * - GCancellable* -> Cancellable 55 * - GInputStream* -> InputStream 56 * module aliases: 57 * local aliases: 58 * overrides: 59 */ 60 61 module gio.LoadableIconIF; 62 63 public import gtkc.giotypes; 64 65 private import gtkc.gio; 66 private import glib.ConstructionException; 67 private import gobject.ObjectG; 68 69 70 private import glib.Str; 71 private import glib.ErrorG; 72 private import glib.GException; 73 private import gio.AsyncResultIF; 74 private import gio.Cancellable; 75 private import gio.InputStream; 76 77 78 79 80 /** 81 * Extends the GIcon interface and adds the ability to 82 * load icons from streams. 83 */ 84 public interface LoadableIconIF 85 { 86 87 88 public GLoadableIcon* getLoadableIconTStruct(); 89 90 /** the main Gtk struct as a void* */ 91 protected void* getStruct(); 92 93 94 /** 95 */ 96 97 /** 98 * Loads a loadable icon. For the asynchronous version of this function, 99 * see g_loadable_icon_load_async(). 100 * Params: 101 * size = an integer. 102 * type = a location to store the type of the 103 * loaded icon, NULL to ignore. [out][allow-none] 104 * cancellable = optional GCancellable object, NULL to ignore. [allow-none] 105 * Returns: a GInputStream to read the icon from. [transfer full] 106 * Throws: GException on failure. 107 */ 108 public InputStream load(int size, out string type, Cancellable cancellable); 109 110 /** 111 * Loads an icon asynchronously. To finish this function, see 112 * g_loadable_icon_load_finish(). For the synchronous, blocking 113 * version of this function, see g_loadable_icon_load(). 114 * Params: 115 * size = an integer. 116 * cancellable = optional GCancellable object, NULL to ignore. [allow-none] 117 * callback = a GAsyncReadyCallback to call when the 118 * request is satisfied. [scope async] 119 * userData = the data to pass to callback function. [closure] 120 */ 121 public void loadAsync(int size, Cancellable cancellable, GAsyncReadyCallback callback, void* userData); 122 123 /** 124 * Finishes an asynchronous icon load started in g_loadable_icon_load_async(). 125 * Params: 126 * res = a GAsyncResult. 127 * type = a location to store the type of the 128 * loaded icon, NULL to ignore. [out][allow-none] 129 * Returns: a GInputStream to read the icon from. [transfer full] 130 * Throws: GException on failure. 131 */ 132 public InputStream loadFinish(AsyncResultIF res, out string type); 133 }