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 module gtk.ShortcutsSection; 26 27 private import gobject.Signals; 28 private import gtk.Box; 29 private import gtk.c.functions; 30 public import gtk.c.types; 31 private import std.algorithm; 32 33 34 /** 35 * A `GtkShortcutsSection` collects all the keyboard shortcuts and gestures 36 * for a major application mode. 37 * 38 * If your application needs multiple sections, you should give each 39 * section a unique [property@Gtk.ShortcutsSection:section-name] and 40 * a [property@Gtk.ShortcutsSection:title] that can be shown in the 41 * section selector of the [class@Gtk.ShortcutsWindow]. 42 * 43 * The [property@Gtk.ShortcutsSection:max-height] property can be used 44 * to influence how the groups in the section are distributed over pages 45 * and columns. 46 * 47 * This widget is only meant to be used with [class@Gtk.ShortcutsWindow]. 48 */ 49 public class ShortcutsSection : Box 50 { 51 /** the main Gtk struct */ 52 protected GtkShortcutsSection* gtkShortcutsSection; 53 54 /** Get the main Gtk struct */ 55 public GtkShortcutsSection* getShortcutsSectionStruct(bool transferOwnership = false) 56 { 57 if (transferOwnership) 58 ownedRef = false; 59 return gtkShortcutsSection; 60 } 61 62 /** the main Gtk struct as a void* */ 63 protected override void* getStruct() 64 { 65 return cast(void*)gtkShortcutsSection; 66 } 67 68 /** 69 * Sets our main struct and passes it to the parent class. 70 */ 71 public this (GtkShortcutsSection* gtkShortcutsSection, bool ownedRef = false) 72 { 73 this.gtkShortcutsSection = gtkShortcutsSection; 74 super(cast(GtkBox*)gtkShortcutsSection, ownedRef); 75 } 76 77 78 /** */ 79 public static GType getType() 80 { 81 return gtk_shortcuts_section_get_type(); 82 } 83 84 /** */ 85 gulong addOnChangeCurrentPage(bool delegate(int, ShortcutsSection) dlg, ConnectFlags connectFlags=cast(ConnectFlags)0) 86 { 87 return Signals.connect(this, "change-current-page", dlg, connectFlags ^ ConnectFlags.SWAPPED); 88 } 89 }